From: Peter C. <pc...@us...> - 2010-02-02 00:00:04
|
Update of /cvsroot/ipbench/ipbench2/src/tests/nfs_latency/libnfs In directory sfp-cvsdas-1.v30.ch3.sourceforge.com:/tmp/cvs-serv4021/src/tests/nfs_latency/libnfs Modified Files: rpc.c Log Message: Updated to current Debian (python-xml no longer exists); fixed compilation without debug_rpc. Index: rpc.c =================================================================== RCS file: /cvsroot/ipbench/ipbench2/src/tests/nfs_latency/libnfs/rpc.c,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** rpc.c 19 Aug 2005 06:11:01 -0000 1.6 --- rpc.c 1 Feb 2010 23:59:52 -0000 1.7 *************** *** 28,37 **** #endif static void ! rpc_print(char *text, unsigned char *data, size_t length){ size_t i, j; - if(0) rpc_print(text, data, length); - printf("%s\n", text); --- 28,36 ---- #endif + #ifdef DEBUG_RPC static void ! rpc_print(const char *text, unsigned char *data, size_t length){ size_t i, j; printf("%s\n", text); *************** *** 48,52 **** } } ! int rpc_send(struct pbuf *pbuf, int fd, struct callback *c) --- 47,55 ---- } } ! #else ! static void rpc_print(const char *text, unsigned char *data, size_t length) ! { ! } ! #endif int rpc_send(struct pbuf *pbuf, int fd, struct callback *c) *************** *** 66,70 **** return -1; /* don't send zero length rpc */ ! //rpc_print("sending:", pbuf->buf, pbuf->pos); r = send(fd, pbuf->buf, pbuf->pos, 0); --- 69,73 ---- return -1; /* don't send zero length rpc */ ! rpc_print("sending:", (unsigned char *)pbuf->buf, pbuf->pos); r = send(fd, pbuf->buf, pbuf->pos, 0); *************** *** 116,120 **** } ! //rpc_print("received:", pbuf->buf, x); /* find and execute callback function */ --- 119,123 ---- } ! rpc_print("received:", (unsigned char *)pbuf->buf, x); /* find and execute callback function */ |