From owner-freebsd-current Fri Jun 16 10: 7:52 2000 Delivered-To: freebsd-current@freebsd.org Received: from quack.kfu.com (quack.kfu.com [170.1.70.2]) by hub.freebsd.org (Postfix) with ESMTP id 0B27137BF5F for ; Fri, 16 Jun 2000 10:07:50 -0700 (PDT) (envelope-from nsayer@medusa.kfu.com) Received: from medusa.kfu.com (medusa.kfu.com [170.1.70.5]) by quack.kfu.com (8.9.2/8.9.3) with ESMTP id KAA59512 for ; Fri, 16 Jun 2000 10:07:47 -0700 (PDT) (envelope-from nsayer@medusa.kfu.com) Received: (from nsayer@localhost) by medusa.kfu.com (8.9.3/8.8.8) id KAA44803 for freebsd-current@freebsd.org; Fri, 16 Jun 2000 10:07:47 -0700 (PDT) (envelope-from nsayer) Date: Fri, 16 Jun 2000 10:07:47 -0700 (PDT) From: Nick Sayer Message-Id: <200006161707.KAA44803@medusa.kfu.com> To: freebsd-current@freebsd.org Subject: CFR: xdr.h fix for xdrproc_t Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG I would like to apply this patch: Index: xdr.h =================================================================== RCS file: /home/ncvs/src/include/rpc/xdr.h,v retrieving revision 1.14 diff -u -r1.14 xdr.h --- xdr.h 1999/12/29 05:00:44 1.14 +++ xdr.h 2000/06/16 17:05:09 @@ -128,14 +128,14 @@ * The opaque pointer generally points to a structure of the data type * to be decoded. If this pointer is 0, then the type routines should * allocate dynamic storage of the appropriate size and return it. + * + * Sometimes there is a third argument, sometimes not. So for correct + * prototyping, ... is required. */ #ifdef _KERNEL typedef bool_t (*xdrproc_t) __P((XDR *, void *, u_int)); #else -/* - * XXX can't actually prototype it, because some take two args!!! - */ -typedef bool_t (*xdrproc_t) __P((/* XDR *, void *, u_int */)); +typedef bool_t (*xdrproc_t) __P((XDR *, ...)); #endif /* Does anyone forsee any difficulties? Not doing this prevents a product I work on from compiling. gcc complains about the number of arguments because in C++ () prototypes a function that takes NO arguments. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message