Skip to contentSkip to conversation

libnfs.a: move clnt_ping() to utils/mount

PATCH In review Chuck Lever 1 participant 1 message Jul 29, 2007

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 18/23 libnfs.a: move clnt_ping() to utils/mount

Continue clean up of mount functionality in libnfs.a by moving clnt_ping() to utils/mount/network.c. Note that socklen_t is an unsigned int... the i386 gcc compiler threw a signedness warning about the 3rd argument of getsockname().

---

 support/include/conn.h  |    2 -
 support/nfs/conn.c      |   75 ---------------------------------------------
 utils/mount/network.c   |   79 +++++++++++++++++++++++++++++++++++++++++++++++
 utils/mount/network.h   |    3 ++
 utils/mount/nfs4mount.c |    1 +
 5 files changed, 83 insertions(+), 77 deletions(-)
support/include/conn.h +0 -2
index 48f5a1c..ee1b686 100644
@@ -28,8 +28,6 @@ typedef struct {
 static const struct timeval TIMEOUT = { 20, 0 };
 static const struct timeval RETRY_TIMEOUT = { 3, 0 };
 
-int clnt_ping(struct sockaddr_in *, const u_long, const u_long, const u_int,
-	      struct sockaddr_in *);
 int get_socket(struct sockaddr_in *, u_int, int, int);
 
 #endif /* _CONN_H */
support/nfs/conn.c +0 -75

78 lines not on this page · raw message

utils/mount/network.c +79 -0

88 lines not on this page · raw message

utils/mount/network.h +3 -0
index b3a5525..0f24a32 100644
@@ -30,6 +30,9 @@
 int probe_bothports(clnt_addr_t *, clnt_addr_t *);
 int nfs_gethostbyname(const char *, struct sockaddr_in *);
 int nfs_call_umount(clnt_addr_t *, dirpath *);
+int clnt_ping(struct sockaddr_in *, const unsigned long,
+		const unsigned long, const unsigned int,
+		struct sockaddr_in *);
 
 int start_statd(void);
 
utils/mount/nfs4mount.c +1 -0
index 4868c08..de97bd6 100644
@@ -46,6 +46,7 @@
 #include "nfs4_mount.h"
 #include "nfs_mount.h"
 #include "error.h"
+#include "network.h"
 
 #if defined(VAR_LOCK_DIR)
 #define DEFAULT_DIR VAR_LOCK_DIR

-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop. Now Search log events and configuration files using AJAX and a browser. Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
NFS maillist - [email protected]
https://lists.sourceforge.net/lists/listinfo/nfs