Nice. Thanks for the help.

73 de Jeff
On Jul 10, 2007, at 3:46 PM, Ralf S. Engelschall wrote:

  RPM Package Manager, CVS Repository
  http://rpm5.org/cvs/
______________________________________________________________________ ______

  Server: rpm5.org                         Name:   Ralf S. Engelschall
  Root:   /v/rpm/cvs                       Email:  [EMAIL PROTECTED]
Module: rpm Date: 10-Jul-2007 21:46:21
  Branch: HEAD                             Handle: 2007071020462000

  Modified files:
    rpm/rpmio               rpmio.h

  Log:
    Woooohoooo, declaring a function and a function pointer is totally
different in ISO C when it comes to "extern". For function declarations the "extern" is acceptable to be left out (although one can provide it here for pedantic reasons). But for the _declaration_ of a function pointer the "extern" is absolutely mandatory. If left out one simply
    _defines_ a global variable of the same name as the function!

This leads to many nice side-effects. Most notable to the nice, correct but rather confusing warning from ld(1) like: "alignment 16 of symbol `Getpass' in ../rpmio/.libs/librpmio.so is smaller than 32 in rpmdeps.o"

  Summary:
    Revision    Changes     Path
    1.54        +1  -1      rpm/rpmio/rpmio.h
______________________________________________________________________ ______

  patch -p0 <<'@@ .'
  Index: rpm/rpmio/rpmio.h
====================================================================== ======
  $ cvs diff -u -r1.53 -r1.54 rpmio.h
  --- rpm/rpmio/rpmio.h 17 Jun 2007 14:49:02 -0000      1.53
  +++ rpm/rpmio/rpmio.h 10 Jul 2007 19:46:20 -0000      1.54
  @@ -664,7 +664,7 @@
    * @param prompt     prompt string
    * @return           password
    */
  -char * (*Getpass) (const char * prompt)
  +extern char * (*Getpass) (const char * prompt)
        /[EMAIL PROTECTED]/;
   char * _GetPass (const char * prompt)
        /[EMAIL PROTECTED]/;
  @@ .
______________________________________________________________________
RPM Package Manager                                    http://rpm5.org
CVS Sources Repository                                [EMAIL PROTECTED]

______________________________________________________________________
RPM Package Manager                                    http://rpm5.org
Developer Communication List                        rpm-devel@rpm5.org

Reply via email to