RPM Community Forums

Mailing List Message of <rpm-devel>

Re: [CVS] RPM: rpm-5_1: rpm/ CHANGES rpm/rpmdb/ tagname.c

From: Jeff Johnson <n3npq@mac.com>
Date: Tue 16 Sep 2008 - 23:18:55 CEST
Message-id: <480D640E-DA9F-4856-8652-32625FF797F0@mac.com>
Note that this patch contains the real flaw with tagType(), LC_ALL=C was
just part of the problem.

Now tested too.

73 de Jeff
On Sep 16, 2008, at 4:48 PM, Jeff Johnson wrote:

>   RPM Package Manager, CVS Repository
>   http://rpm5.org/cvs/
>    
> ______________________________________________________________________ 
> ______
>
>   Server: rpm5.org                         Name:   Jeff Johnson
>   Root:   /v/rpm/cvs                       Email:  jbj@rpm5.org
>   Module: rpm                              Date:   16-Sep-2008  
> 22:48:05
>   Branch: rpm-5_1                          Handle: 2008091620480400
>
>   Modified files:           (Branch: rpm-5_1)
>     rpm                     CHANGES
>     rpm/rpmdb               tagname.c
>
>   Log:
>     - jbj: fix: tagType() with multiple aliases returned the wrong  
> type.
>
>   Summary:
>     Revision    Changes     Path
>     1.2288.2.111+1  -0      rpm/CHANGES
>     1.28.2.2    +2  -3      rpm/rpmdb/tagname.c
>    
> ______________________________________________________________________ 
> ______
>
>   patch -p0 <<'@@ .'
>   Index: rpm/CHANGES
>    
> ====================================================================== 
> ======
>   $ cvs diff -u -r1.2288.2.110 -r1.2288.2.111 CHANGES
>   --- rpm/CHANGES	16 Sep 2008 16:51:22 -0000	1.2288.2.110
>   +++ rpm/CHANGES	16 Sep 2008 20:48:04 -0000	1.2288.2.111
>   @@ -1,4 +1,5 @@
>    5.1.4 -> 5.1.5:
>   +    - jbj: fix: tagType() with multiple aliases returned the  
> wrong type.
>        - jbj: sqlite: fix: insure that tagType() returns result  
> from stable sort.
>        - rse: upgrade build environment to GNU libtool 2.2.6
>        - jbj: lua: fix: don't unlink a non-existent scriptlet file.
>   @@ .
>   patch -p0 <<'@@ .'
>   Index: rpm/rpmdb/tagname.c
>    
> ====================================================================== 
> ======
>   $ cvs diff -u -r1.28.2.1 -r1.28.2.2 tagname.c
>   --- rpm/rpmdb/tagname.c	18 May 2008 14:40:30 -0000	1.28.2.1
>   +++ rpm/rpmdb/tagname.c	16 Sep 2008 20:48:04 -0000	1.28.2.2
>   @@ -261,9 +261,8 @@
>    		/* Make sure that the bsearch retrieve is stable. */
>    		while (i > 0 && tag == _rpmTags.byValue[i-1]->val) {
>    		    i--;
>   -		    t--;
>   -		}
>    		t = _rpmTags.byValue[i];
>   +		}
>    		s = (*_rpmTags.tagCanonicalize) (t->name);
>    		strncpy(nameBuf, s, nameBufLen);
>    		s = _free(s);
>   @@ -322,7 +321,7 @@
>    		/* Make sure that the bsearch retrieve is stable. */
>    		while (i > 0 && t->val == _rpmTags.byValue[i-1]->val) {
>    		    i--;
>   -		    t--;
>   +		    t = _rpmTags.byValue[i];
>    		}
>    		return t->type;
>    	    }
>   @@ .
> ______________________________________________________________________
> RPM Package Manager                                    http://rpm5.org
> CVS Sources Repository                                rpm-cvs@rpm5.org
Received on Tue Sep 16 23:19:03 2008
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.