[packages/abrt] - added fixes for bohdi plugin

baggins baggins at pld-linux.org
Mon Oct 15 16:00:43 CEST 2012


commit 1d2696de1070666b229843fa7326e1134842776b
Author: Jan Rękorajski <baggins at pld-linux.org>
Date:   Mon Oct 15 15:55:32 2012 +0200

    - added fixes for bohdi plugin

 abrt-rpm5.patch | 32 ++++++++++++++++++++++++++++++++
 1 file changed, 32 insertions(+)
---
diff --git a/abrt-rpm5.patch b/abrt-rpm5.patch
index b0cd0d1..a86098e 100644
--- a/abrt-rpm5.patch
+++ b/abrt-rpm5.patch
@@ -190,3 +190,35 @@
  
  #ifdef __cplusplus
  extern "C" {
+--- abrt-2.0.15/src/plugins/bodhi.c~	2012-10-05 08:30:34.000000000 +0200
++++ abrt-2.0.15/src/plugins/bodhi.c	2012-10-15 15:54:12.298943477 +0200
+@@ -331,24 +331,23 @@
+     char *nvr = NULL;
+ 
+     rpmts ts = rpmtsCreate();
+-    rpmdbMatchIterator iter = rpmtsInitIterator(ts, RPMTAG_NAME, pkg_name, 0);
+-    Header header = rpmdbNextIterator(iter);
++    rpmmi iter = rpmtsInitIterator(ts, RPMTAG_NAME, pkg_name, 0);
++    Header header = rpmmiNext(iter);
+ 
+     if (!header)
+         goto error;
+ 
+     const char *errmsg = NULL;
+-    nvr = headerFormat(header, "%{name}-%{version}-%{release}", &errmsg);
++    nvr = headerSprintf(header, "%{name}-%{version}-%{release}", NULL, NULL, &errmsg);
+ 
+     if (!nvr && errmsg)
+         error_msg("cannot get nvr. reason: %s", errmsg);
+ 
+ error:
+-    rpmdbFreeIterator(iter);
+-    rpmtsFree(ts);
++    iter = rpmmiFree(iter);
++    ts = rpmtsFree(ts);
+ 
+     rpmFreeRpmrc();
+-    rpmFreeCrypto();
+     rpmFreeMacros(NULL);
+ 
+     return nvr;
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/abrt.git/commitdiff/363a1810a81c51dd89434b5d14dac11708370cd2



More information about the pld-cvs-commit mailing list