#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>
#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>
}
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;
ret = readt(db->fd, rply, sizeof(struct cnid_dbd_rply), 0, ONE_DELAY);
if (ret != sizeof(struct cnid_dbd_rply)) {
- LOG(log_error, logtype_cnid, "dbd_rpc: Error reading header from fd (db_dir %s): %s",
+ LOG(log_debug, logtype_cnid, "dbd_rpc: Error reading header from fd (db_dir %s): %s",
db->db_dir, ret == -1 ? strerror(errno) : "closed");
rply->name = nametmp;
return -1;