packages/net/nfs-kernel-server/patches/001-nfs_utils_1.0.6_uclibc.patch
nbd 187172fdd0 fix nfs-kernel-server compile
git-svn-id: svn://svn.openwrt.org/openwrt/packages@10055 3c298f89-4303-0410-b956-a3cf2f4a3e73
2007-12-30 15:55:21 +00:00

25 lines
750 B
Diff

Index: nfs-utils-1.0.7/support/nfs/svc_socket.c
===================================================================
--- nfs-utils-1.0.7.orig/support/nfs/svc_socket.c 2007-12-30 16:52:24.647893048 +0100
+++ nfs-utils-1.0.7/support/nfs/svc_socket.c 2007-12-30 16:53:46.880579218 +0100
@@ -63,9 +63,10 @@
}
}
- __bzero ((char *) &addr, sizeof (addr));
+ memset((char *) &addr, 0, sizeof (addr));
addr.sin_family = AF_INET;
+#ifndef __UCLIBC__ /* neither getrpcbynumber() nor getrpcbynumber_r() is SuSv3 */
ret = getrpcbynumber_r (number, &rpcbuf, rpcdata, sizeof rpcdata,
&rpcp);
if (ret == 0 && rpcp != NULL)
@@ -99,6 +100,7 @@
}
}
else
+#endif /* ! __UCLIBC__ */
{
if (bindresvport (sock, &addr))
{