diff options
Diffstat (limited to 'network/dsniff/patches/36_implicit_declarations.patch')
-rw-r--r-- | network/dsniff/patches/36_implicit_declarations.patch | 59 |
1 files changed, 59 insertions, 0 deletions
diff --git a/network/dsniff/patches/36_implicit_declarations.patch b/network/dsniff/patches/36_implicit_declarations.patch new file mode 100644 index 0000000000..159f7c2b32 --- /dev/null +++ b/network/dsniff/patches/36_implicit_declarations.patch @@ -0,0 +1,59 @@ +Description: fix implicit declarations compiler warning + * switch to C99 uint64_t, remove now unnecessary xdr_u_int64_t function + * include missing string.h for memset +Author: Lukas Schwaighofer <lukas@schwaighofer.name> + +--- a/filesnarf.c ++++ b/filesnarf.c +@@ -55,30 +55,6 @@ + exit(1); + } + +-/* XXX - for nfs_prot_xdr.c */ +-bool_t +-xdr_u_int64_t(XDR *xdrs, u_int64_t *nump) +-{ +- int i = 1; +- u_char *p = (u_char *)nump; +- +- if (*(char *)&i == 1) { /* endian haack. */ +- if (xdr_u_long(xdrs, (u_long *)(p + 4))) +- return (xdr_u_long(xdrs, (u_long *)p)); +- } +- else { +- if (xdr_u_long(xdrs, (u_long *)p)) +- return (xdr_u_long(xdrs, (u_long *)(p + 4))); +- } +- return (FALSE); +-} +- +-bool_t +-xdr_int64_t(XDR *xdrs, int64_t *nump) +-{ +- return (xdr_u_int64_t(xdrs, (u_int64_t *)nump)); +-} +- + static void + fh_map_init(void) + { +--- a/nfs_prot.x ++++ b/nfs_prot.x +@@ -190,7 +190,7 @@ + /* + * Basic data types + */ +-typedef u_int64_t uint64; ++typedef uint64_t uint64; + typedef int64_t int64; + typedef unsigned int uint32; + typedef int int32; +--- a/sshcrypto.c ++++ b/sshcrypto.c +@@ -20,6 +20,7 @@ + #include <err.h> + #include <stdio.h> + #include <stdlib.h> ++#include <string.h> + + #include "sshcrypto.h" + |