RPM Community Forums

Mailing List Message of <rpm-devel>

Re: [CVS] RPM: popt/ CHANGES acinclude.m4

From: Jeff Johnson <n3npq@mac.com>
Date: Sun 09 Mar 2008 - 16:30:51 CET
Message-Id: <E172439E-B3EE-460C-AD2A-8CA8BCBB62FE@mac.com>
I *think* that rewriting POPT_fprintf(), thereby eliminating passing
"va_list ap" to strdup_fprintf() as an argument, eliminates the need  
for acinclude.m4
testing for va_copy().

If I'm wrong, the fixing to do va_copy() in POPT_fprintf() is the  
obvious solution.

Nicely done AutoFu no matter what ...

73 de Jeff

On Mar 9, 2008, at 3:14 AM, 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:  rse@rpm5.org
>   Module: popt                             Date:   09-Mar-2008  
> 08:14:06
>   Branch: HEAD                             Handle: 2008030907140600
>
>   Modified files:
>     popt                    CHANGES acinclude.m4
>
>   Log:
>     Fix memcpy(3) based va_copy(3) fallbacks
>
>   Summary:
>     Revision    Changes     Path
>     1.69        +1  -0      popt/CHANGES
>     1.2         +2  -2      popt/acinclude.m4
>    
> ______________________________________________________________________ 
> ______
>
>   patch -p0 <<'@@ .'
>   Index: popt/CHANGES
>    
> ====================================================================== 
> ======
>   $ cvs diff -u -r1.68 -r1.69 CHANGES
>   --- popt/CHANGES	9 Mar 2008 06:01:05 -0000	1.68
>   +++ popt/CHANGES	9 Mar 2008 07:14:06 -0000	1.69
>   @@ -1,4 +1,5 @@
>    1.13 -> 1.14:
>   +    - rse: fix memcpy(3) based va_copy(3) fallbacks
>        - jbj: fix: short option with "foo=bar" argument was  
> mishandled.
>    	(Wayne Davison<wayned@samba.org>).
>        - jbj: rename _ABS to avoid collisions, define DBL_EPSILON  
> if not present
>   @@ .
>   patch -p0 <<'@@ .'
>   Index: popt/acinclude.m4
>    
> ====================================================================== 
> ======
>   $ cvs diff -u -r1.1 -r1.2 acinclude.m4
>   --- popt/acinclude.m4	15 Jun 2007 14:06:06 -0000	1.1
>   +++ popt/acinclude.m4	9 Mar 2008 07:14:06 -0000	1.2
>   @@ -82,9 +82,9 @@
>        dnl #   6. check for assignment approach (assuming va_list  
> is a pointer)
>        __va_copy_check(ASP, [do { *(d) = *(s); } while (0)])
>        dnl #   7. check for memory copying approach (assuming  
> va_list is a struct)
>   -    __va_copy_check(CPS, [memcpy((void *)&(d), (void *)&(s)),  
> sizeof((s))])
>   +    __va_copy_check(CPS, [memcpy((void *)&(d), (void *)&(s),  
> sizeof((s)))])
>        dnl #   8. check for memory copying approach (assuming  
> va_list is a pointer)
>   -    __va_copy_check(CPP, [memcpy((void *)(d), (void *)(s)),  
> sizeof(*(s))])
>   +    __va_copy_check(CPP, [memcpy((void *)(d), (void *)(s), sizeof 
> (*(s)))])
>        if test ".$ac_cv_va_copy" = .; then
>            AC_ERROR([no working implementation found])
>        fi
>   @@ .
> ______________________________________________________________________
> RPM Package Manager                                    http://rpm5.org
> CVS Sources Repository                                rpm-cvs@rpm5.org
Received on Sun Mar 9 16:31:00 2008
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.