#include <sys/stat.h>
#endif /* HAVE_SYS_STAT_H */
#include <netinet/in.h>
+#include <netinet/tcp.h>
#include <arpa/inet.h>
#include <setjmp.h>
#include <time.h>
#include "fork.h"
#include "dircache.h"
+#ifndef SOL_TCP
+#define SOL_TCP IPPROTO_TCP
+#endif
+
/*
* We generally pass this from afp_over_dsi to all afp_* funcs, so it should already be
* available everywhere. Unfortunately some funcs (eg acltoownermode) need acces to it
}
}
- close_all_vol();
+ close_all_vol(obj);
if (obj->logout)
(*obj->logout)();
}
}
+ /* set TCP_NODELAY */
+ int flag = 1;
+ setsockopt(dsi->socket, SOL_TCP, TCP_NODELAY, &flag, sizeof(flag));
+
/* get stuck here until the end */
while (1) {
if (sigsetjmp(recon_jmp, 1) != 0)
if (reload_request) {
reload_request = 0;
- load_volumes(AFPobj, of_closevol);
+ load_volumes(AFPobj, closevol);
}
/* The first SIGINT enables debugging, the next restores the config */