Print this page
8654 unused local typedef in rpc code

*** 23,32 **** --- 23,33 ---- * Copyright 2004 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ /* * Copyright 2012 Nexenta Systems, Inc. All rights reserved. + * Copyright 2017 RackTop Systems. */ #include <rpc/types.h> #include <rpc/xdr.h> #include <sys/types.h>
*** 111,124 **** { XDR x; struct xdr_ops ops; bool_t stat; /* to stop ANSI-C compiler from complaining */ ! typedef bool_t (* dummyfunc1)(XDR *, long *); ! typedef bool_t (* dummyfunc2)(XDR *, caddr_t, int); typedef bool_t (* dummyfunc3)(XDR *, int32_t *); ! typedef bool_t (* dummyfunc4)(XDR *, int, void *); ops.x_putbytes = x_putbytes; ops.x_inline = x_inline; ops.x_getpostn = x_getpostn; ops.x_setpostn = x_setpostn; --- 112,126 ---- { XDR x; struct xdr_ops ops; bool_t stat; /* to stop ANSI-C compiler from complaining */ ! typedef bool_t (* dummyfunc1)(XDR *, caddr_t, int); ! typedef bool_t (* dummyfunc2)(XDR *, int, void *); ! #if defined(_LP64) || defined(_KERNEL) typedef bool_t (* dummyfunc3)(XDR *, int32_t *); ! #endif ops.x_putbytes = x_putbytes; ops.x_inline = x_inline; ops.x_getpostn = x_getpostn; ops.x_setpostn = x_setpostn;
*** 128,139 **** ops.x_getint32 = (dummyfunc3)harmless; ops.x_putint32 = x_putint32_t; #endif /* the other harmless ones */ ! ops.x_getbytes = (dummyfunc2)harmless; ! ops.x_control = (dummyfunc4)harmless; x.x_op = XDR_ENCODE; x.x_ops = &ops; x.x_handy = 0; x.x_private = (caddr_t)NULL; --- 130,141 ---- ops.x_getint32 = (dummyfunc3)harmless; ops.x_putint32 = x_putint32_t; #endif /* the other harmless ones */ ! ops.x_getbytes = (dummyfunc1)harmless; ! ops.x_control = (dummyfunc2)harmless; x.x_op = XDR_ENCODE; x.x_ops = &ops; x.x_handy = 0; x.x_private = (caddr_t)NULL;