RPM Community Forums

Mailing List Message of <rpm-cvs>

[CVS] RPM: rpm-4_5: rpm/ CHANGES rpm/rpmdb/ header.c

From: Jeff Johnson <jbj@rpm5.org>
Date: Wed 24 Oct 2007 - 08:35:14 CEST
Message-Id: <20071024063514.51DE1348454@rpm5.org>
  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:   24-Oct-2007 08:35:14
  Branch: rpm-4_5                          Handle: 2007102407351301

  Modified files:           (Branch: rpm-4_5)
    rpm                     CHANGES
    rpm/rpmdb               header.c

  Log:
    - jbj: completed tag container backport.
    - jbj: fix: RPM_I18NSTRING_TYPE was being returned as argv array with --xml.

  Summary:
    Revision    Changes     Path
    1.1360.2.48 +2  -0      rpm/CHANGES
    1.48.2.15   +4  -2      rpm/rpmdb/header.c
  ____________________________________________________________________________

  patch -p0 <<'@@ .'
  Index: rpm/CHANGES
  ============================================================================
  $ cvs diff -u -r1.1360.2.47 -r1.1360.2.48 CHANGES
  --- rpm/CHANGES	23 Oct 2007 16:43:12 -0000	1.1360.2.47
  +++ rpm/CHANGES	24 Oct 2007 06:35:13 -0000	1.1360.2.48
  @@ -1,4 +1,6 @@
   4.4.9 -> 4.5:
  +    - jbj: completed tag container backport.
  +    - jbj: fix: RPM_I18NSTRING_TYPE was being returned as argv array with --xml.
       - jbj: eliminate warnings.
       - jbj: keep the headerFoo() API invariant, eliminate warnings.
       - jbj: backport (and enable) tag data cache.
  @@ .
  patch -p0 <<'@@ .'
  Index: rpm/rpmdb/header.c
  ============================================================================
  $ cvs diff -u -r1.48.2.14 -r1.48.2.15 header.c
  --- rpm/rpmdb/header.c	24 Oct 2007 05:37:27 -0000	1.48.2.14
  +++ rpm/rpmdb/header.c	24 Oct 2007 06:35:14 -0000	1.48.2.15
  @@ -1506,6 +1506,9 @@
   		: entry->data);
   	}
   	break;
  +    case RPM_I18NSTRING_TYPE:
  +	count = 1;	/* XXX wrong for headerGetRawEntry() */
  +	/*@fallthrough@*/
       case RPM_STRING_TYPE:
   	if (count == 1) {
   	    (*p).str = entry->data;
  @@ -1513,7 +1516,6 @@
   	}
   	/*@fallthrough@*/
       case RPM_STRING_ARRAY_TYPE:
  -    case RPM_I18NSTRING_TYPE:
       {	const char ** argv;
   	size_t nb = count * sizeof(*argv);
   	char * t;
  @@ -3344,6 +3346,7 @@
   
       if (he->p.ptr)
       switch (he->t) {
  +    case RPM_I18NSTRING_TYPE:	/* XXX this should never be seen. */
       default:
   	val = xstrdup("(unknown type)");
   	need = strlen(val) + 1;
  @@ -3368,7 +3371,6 @@
   
   	break;
   
  -    case RPM_I18NSTRING_TYPE:	/* XXX this should _NOT_ be needed. */
       case RPM_STRING_TYPE:
   	if (tag->fmt)
   	    val = tag->fmt(RPM_STRING_TYPE, he->p.ptr, buf, tag->pad,  -1);
  @@ .
Received on Wed Oct 24 08:35:14 2007
Driven by Jeff Johnson and the RPM project team.
Hosted by OpenPKG and Ralf S. Engelschall.
Powered by FreeBSD and OpenPKG.