]> arthur.barton.de Git - netatalk.git/blobdiff - libatalk/cnid/dbd/cnid_dbd.c
Merge master
[netatalk.git] / libatalk / cnid / dbd / cnid_dbd.c
index ab5a20f267af0850e979cbf5c10dc9afc66a1813..b7e1f4035f856b3480ef37bfd249139e77624a58 100644 (file)
 #ifdef CNID_BACKEND_DBD
 
 #include <stdlib.h>
-#ifdef HAVE_SYS_STAT_H
 #include <sys/stat.h>
-#endif /* HAVE_SYS_STAT_H */
-#ifdef HAVE_SYS_UIO_H
 #include <sys/uio.h>
-#endif /* HAVE_SYS_UIO_H */
-#ifdef HAVE_STRINGS_H
-#include <strings.h>
-#endif
 #include <sys/time.h>
 #include <sys/un.h>
 #include <sys/socket.h>
@@ -33,8 +26,8 @@
 #include <errno.h>
 #include <netdb.h>
 #include <time.h>
+#include <arpa/inet.h>
 
-#include <netatalk/endian.h>
 #include <atalk/logger.h>
 #include <atalk/adouble.h>
 #include <atalk/cnid.h>
@@ -104,7 +97,7 @@ static int tsock_getfd(const char *host, const char *port)
         }
 
         if (setnonblock(sock, 1) != 0) {
-            LOG(log_error, logtype_cnid, "getfd: setnonblock: %s", strerror(err));
+            LOG(log_error, logtype_cnid, "getfd: setnonblock: %s", strerror(errno));
             close(sock);
             sock = -1;
             return -1;