Attempt to resurrect trb
authorPanu Matilainen <pmatilai@redhat.com>
Thu, 9 Aug 2007 08:22:40 +0000 (11:22 +0300)
committerPanu Matilainen <pmatilai@redhat.com>
Thu, 9 Aug 2007 08:22:40 +0000 (11:22 +0300)
lib/trb.c

index 900b2e7..6da0a70 100644 (file)
--- a/lib/trb.c
+++ b/lib/trb.c
@@ -1,6 +1,7 @@
 #include "system.h"
 #include "rpmcli.h"
 #include "misc.h"
+#include "rpmts.h"
 
 #include "debug.h"
 
@@ -23,6 +24,7 @@ main(int argc, const char *argv[])
     struct rpmInstallArguments_s * ia = &rpmIArgs;
     int arg;
     int ec = 0;
+    rpmts ts;
 
 #if HAVE_MCHECK_H && HAVE_MTRACE
     mtrace();   /* Trace malloc only if MALLOC_TRACE=mtrace-output-file. */
@@ -60,7 +62,9 @@ main(int argc, const char *argv[])
     if (rpmReadConfigFiles(NULL, NULL))
        exit(1);
 
-    ec = rpmRollback(ia, NULL);
+    ts = rpmtsCreate();
+    ec = rpmRollback(ts, ia, NULL);
+    ts = rpmtsFree(ts);
 
     optCon = poptFreeContext(optCon);
     rpmFreeMacros(NULL);