[Date Prev][Date Next] [Chronological] [Thread] [Top]

Inconsistent calling convention declarations cause compile errors (ITS#1074)

Full_Name: Dave Steck
Version: devel
OS: NT, Solaris, Linux, NetWare
URL: ftp://ftp.openldap.org/incoming/
Submission from: (NULL) (

The calling convention declarations are not declared consistenly 
between the include file and source files.  Causes compiler errors
on some platforms.

For example, the include file declares the prototype:
   LDAP_F( int )
   ldap_search_ext_s ...

But the source file declares the function:
   ldap_search_ext_s ...

The whole point of making the explicit declaration is so we don't depend 
on the compiler's default setting.  So they *must* be declared consistently.
It's difficult for us to keep synched with OpenLDAP when we have to modify
the calling conventions on every file.

The second issue is which functions have the explicit declaration and which
Any functions exported by the library must be declared explicitly.  
Purely internal functions don't.  But it's not exactly clear which functions 
the developer is going to export.  Either you take a guess at what functions
might be exported and declare those, or else declare everything.

Thanks, this is a great work.