Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/dist/smbfs/lib/smb no need for iconv.h include here
details: https://anonhg.NetBSD.org/src/rev/9a3ccadac202
branches: trunk
changeset: 543142:9a3ccadac202
user: jdolecek <jdolecek%NetBSD.org@localhost>
date: Tue Feb 18 09:47:48 2003 +0000
description:
no need for iconv.h include here
no \n on end of warn() format
include <sys/param.h> for some contants
iconv_loaded--, not iconv_loaded++ when the dlopen() fails
diffstat:
dist/smbfs/lib/smb/nls.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diffs (33 lines):
diff -r f15642bc575d -r 9a3ccadac202 dist/smbfs/lib/smb/nls.c
--- a/dist/smbfs/lib/smb/nls.c Tue Feb 18 09:45:58 2003 +0000
+++ b/dist/smbfs/lib/smb/nls.c Tue Feb 18 09:47:48 2003 +0000
@@ -32,8 +32,8 @@
* from: Id: nls.c,v 1.10 2002/07/22 08:33:59 bp Exp
*/
+#include <sys/param.h>
#include <sys/types.h>
-#include <sys/iconv.h>
#include <sys/sysctl.h>
#include <ctype.h>
#ifndef APPLE
@@ -69,7 +69,7 @@
int i;
if (setlocale(LC_CTYPE, name) == NULL) {
- warnx("can't set locale '%s'\n", name);
+ warnx("can't set locale '%s'", name);
return EINVAL;
}
for (i = 0; i < 256; i++) {
@@ -93,8 +93,8 @@
iconv_loaded++;
iconv_lib = dlopen("libiconv.so", RTLD_LAZY | RTLD_GLOBAL);
if (iconv_lib == NULL) {
- warn("Unable to load iconv library: %s\n", dlerror());
- iconv_loaded++;
+ warnx("Unable to load iconv library: %s", dlerror());
+ iconv_loaded--;
return ENOENT;
}
my_iconv_open = dlsym(iconv_lib, "iconv_open");
Home |
Main Index |
Thread Index |
Old Index