Why are you reverting? The issue in the comment has already been fixed by committing to
a representation for missing values.

73 de Jeff


On Aug 5, 2009, at 8:56 PM, Per Øyvind Karlsen wrote:

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

 Server: rpm5.org                         Name:   Per Øyvind Karlsen
 Root:   /v/rpm/cvs                       Email:  pkarl...@rpm5.org
 Module: rpm                              Date:   06-Aug-2009 02:56:20
 Branch: HEAD                             Handle: 2009080600562000

 Modified files:
   rpm                     CHANGES
   rpm/rpmdb               rpmevr.c

 Log:
   rpmevr: make rpmEVRparse() work with missing values.

 Summary:
   Revision    Changes     Path
   1.3085      +1  -0      rpm/CHANGES
   1.33        +7  -1      rpm/rpmdb/rpmevr.c
____________________________________________________________________________

 patch -p0 <<'@@ .'
 Index: rpm/CHANGES
= = = = = = ======================================================================
 $ cvs diff -u -r1.3084 -r1.3085 CHANGES
 --- rpm/CHANGES        6 Aug 2009 00:52:27 -0000       1.3084
 +++ rpm/CHANGES        6 Aug 2009 00:56:20 -0000       1.3085
 @@ -1,5 +1,6 @@

  5.2b1 -> 5.3a1
 +    - proyvind: rpmevr: make rpmEVRparse() work with missing values.
- proyvind: rpm46compat: Implement RPM 4.6 API wrapper providing ~seamless
        API compatibility for the function wrappers provided. :)
- proyvind: python: start on implementing proper regression tests.
 @@ .
 patch -p0 <<'@@ .'
 Index: rpm/rpmdb/rpmevr.c
= = = = = = ======================================================================
 $ cvs diff -u -r1.32 -r1.33 rpmevr.c
 --- rpm/rpmdb/rpmevr.c 27 Mar 2009 17:42:00 -0000      1.32
 +++ rpm/rpmdb/rpmevr.c 6 Aug 2009 00:56:20 -0000       1.33
 @@ -212,7 +212,13 @@

      }

- evr->Elong = evr->F[RPMEVR_E] ? strtoul(evr->F[RPMEVR_E], NULL, 10) : 0; + /* XXX HACK: postpone committing to single "missing" value for now. */
 +    if (evr->F[RPMEVR_E] == NULL) evr->F[RPMEVR_E] = "0";
 +    if (evr->F[RPMEVR_V] == NULL) evr->F[RPMEVR_V] = "";
 +    if (evr->F[RPMEVR_R] == NULL) evr->F[RPMEVR_R] = "";
 +    if (evr->F[RPMEVR_D] == NULL) evr->F[RPMEVR_D] = "";
 +
 +    evr->Elong = strtoul(evr->F[RPMEVR_E], NULL, 10);

      xx = mireSetEOptions(mire, NULL, 0);

 @@ .
______________________________________________________________________
RPM Package Manager                                    http://rpm5.org
CVS Sources Repository                                rpm-...@rpm5.org

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

Reply via email to