[Python-bugs-list] [ python-Bugs-657625 ] nismodule gives a compiletime warning

noreply@sourceforge.net noreply@sourceforge.net
Mon, 23 Dec 2002 14:11:31 -0800


Bugs item #657625, was opened at 2002-12-22 23:27
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=657625&group_id=5470

Category: Extension Modules
Group: None
Status: Open
Resolution: None
Priority: 2
Submitted By: Jack Jansen (jackjansen)
Assigned to: Nobody/Anonymous (nobody)
Summary: nismodule gives a compiletime warning

Initial Comment:
Nismodule gives a compile time warning on MacOSX.

It has a typedef of a foreachfunc with the signature
typedef int (*foreachfunc)(int, char *, int, char *, int, char *);
but the corresponding item to which this function is assigned (from ypcInt.h) has signature
int (*foreach) __P((u_long, char *, int, char *, int, void *));

Someone with more understanding of NIS will have to fix this.

----------------------------------------------------------------------

>Comment By: Martin v. Löwis (loewis)
Date: 2002-12-23 23:11

Message:
Logged In: YES 
user_id=21627

I would say this is a bug in your header file. There is,
historically, no symbolic typedef for the foreach function,
but the officially documented prototype (i.e. the on of the
Sun documentation) uses an int argument. 

Nearly all other systems follow this specification; see
#633013 for the most recent verification of this detail (for
Tru64).

I would discourage a change that specifically checks for OS
X. If you think this needs to be fixed, please design an
autoconf test to check for the argument of the foreach
function; to implement such a test, you might need to
convert the warning to an error, which might in turn mean
that the test can only be executed for gcc.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=105470&aid=657625&group_id=5470