poldek: poldek/configure.in, poldek/libpoldek.sym, poldek/poldek_t...

mis mis at pld-linux.org
Fri Jun 29 00:28:26 CEST 2007


Author: mis                          Date: Thu Jun 28 22:28:26 2007 GMT
Module: poldek                        Tag: HEAD
---- Log message:
- moved poldek_iinf to poldek_ts to be easly exposed to python module

---- Files affected:
poldek/poldek:
   configure.in (1.139 -> 1.140) , libpoldek.sym (1.27 -> 1.28) , poldek_ts.c (1.64 -> 1.65) , poldek_ts.h (1.38 -> 1.39) , uninstall.c (1.42 -> 1.43) , upgrade-dist.c (1.4 -> 1.5) 
poldek/poldek/cli:
   cli.c (1.40 -> 1.41) , cli.h (1.16 -> 1.17) , install.c (1.43 -> 1.44) , op_verify.c (1.16 -> 1.17) , uninstall.c (1.30 -> 1.31) 
poldek/poldek/install:
   install.c (1.8 -> 1.9) , install.h (1.2 -> 1.3) 

---- Diffs:

================================================================
Index: poldek/poldek/configure.in
diff -u poldek/poldek/configure.in:1.139 poldek/poldek/configure.in:1.140
--- poldek/poldek/configure.in:1.139	Wed Jun 27 02:44:47 2007
+++ poldek/poldek/configure.in	Fri Jun 29 00:28:21 2007
@@ -6,7 +6,7 @@
 AC_CONFIG_SRCDIR([capreq.c])
 
 PACKAGE_BUGREPORT="mis at pld-linux.pl"
-VERSION_STATUS="alpha"
+VERSION_STATUS="beta"
 VERSION=0.21
 VERSION_TAG=$(echo $VERSION | sed 's/\./_/g')
 VERSION_CVSTAG="v$VERSION_TAG"

================================================================
Index: poldek/poldek/libpoldek.sym
diff -u poldek/poldek/libpoldek.sym:1.27 poldek/poldek/libpoldek.sym:1.28
--- poldek/poldek/libpoldek.sym:1.27	Wed Jun 27 02:44:47 2007
+++ poldek/poldek/libpoldek.sym	Fri Jun 29 00:28:21 2007
@@ -253,12 +253,10 @@
 poldek_ts_clean_args
 poldek_ts_clrf
 poldek_ts_configure
-poldek_ts_destroy
 poldek_ts_free
 poldek_ts_get_arg_count
 poldek_ts_get_args_asmasks
 poldek_ts_getop
-poldek_ts_init
 poldek_ts_is_interactive_on
 poldek_ts_issetf
 poldek_ts_issetf_all

================================================================
Index: poldek/poldek/poldek_ts.c
diff -u poldek/poldek/poldek_ts.c:1.64 poldek/poldek/poldek_ts.c:1.65
--- poldek/poldek/poldek_ts.c:1.64	Wed Jun 27 02:44:47 2007
+++ poldek/poldek/poldek_ts.c	Fri Jun 29 00:28:21 2007
@@ -61,14 +61,15 @@
 extern
 int do_poldek_ts_upgrade_dist(struct poldek_ts *ts);
 extern
-int do_poldek_ts_uninstall(struct poldek_ts *ts, struct poldek_iinf *iinf);
+int do_poldek_ts_uninstall(struct poldek_ts *ts);
 
 
-static int ts_run_install(struct poldek_ts *ts, struct poldek_iinf *iinf);
-static int ts_run_uninstall(struct poldek_ts *ts, struct poldek_iinf *iinf);
-static int ts_run_verify(struct poldek_ts *ts, void *);
+static int ts_run_install(struct poldek_ts *ts);
+static int ts_run_uninstall(struct poldek_ts *ts);
+static int ts_run_verify(struct poldek_ts *ts);
+
+typedef int (*ts_run_fn)(struct poldek_ts *);
 
-typedef int (*ts_run_fn)(struct poldek_ts *, void *);
 struct ts_run {
     int        type;
     ts_run_fn  run;
@@ -87,6 +88,10 @@
 
 #define TS_CONFIG_LATER (1 << 0)
 
+static int poldek_ts_init(struct poldek_ts *ts, struct poldek_ctx *ctx);
+static void poldek_ts_destroy(struct poldek_ts *ts);
+
+
 struct poldek_ts *poldek_ts_new(struct poldek_ctx *ctx, unsigned flags)
 {
     struct poldek_ts *ts;
@@ -178,7 +183,7 @@
         bitvect_clr(ts->_opvect, optv);
     
     if (touch)
-        bitvect_set(ts->_opvect_setmark, optv); /* touched */
+        bitvect_set(ts->_opvect_touched, optv); /* touched */
 }
 
 void poldek_ts_setop(struct poldek_ts *ts, int optv, int on)
@@ -196,7 +201,7 @@
 int poldek_ts_op_touched(const struct poldek_ts *ts, int optv)
 {
     n_assert(bitvect_slot(optv) < sizeof(ts->_opvect)/sizeof(bitvect_slot_itype));
-    return bitvect_isset(ts->_opvect_setmark, optv) > 0;
+    return bitvect_isset(ts->_opvect_touched, optv) > 0;
 }
 
 int poldek_ts_getop_v(const struct poldek_ts *ts, int optv, ...)
@@ -231,7 +236,7 @@
         *dst = NULL;
 }
 
-int poldek_ts_init(struct poldek_ts *ts, struct poldek_ctx *ctx)
+static int poldek_ts_init(struct poldek_ts *ts, struct poldek_ctx *ctx)
 {
     memset(ts, 0, sizeof(*ts));
     ts->setop = poldek_ts_setop;
@@ -253,7 +258,7 @@
     ts->_na = n_alloc_new(4, TN_ALLOC_OBSTACK);
     ts->db = NULL;
 
-    if (ctx) {
+    if (ctx) {  /* copy configuration from ctx's ts */
         cp_str(&ts->rootdir, ctx->ts->rootdir);
         cp_str(&ts->fetchdir, ctx->ts->fetchdir);
         cp_str(&ts->cachedir, ctx->ts->cachedir);
@@ -271,7 +276,7 @@
         ts->exclude_path = n_array_dup(ctx->ts->exclude_path,
                                        (tn_fn_dup)strdup);
         
-    } else {
+    } else {                    /* no ctx? -> it's ctx internal ts */
         ts->rootdir = NULL;
         ts->fetchdir = NULL;
         ts->cachedir = NULL;
@@ -289,11 +294,13 @@
     ts->askpkg_fn = poldek_term_ask_pkg;
     ts->ask_fn = poldek_term_ask_yn;
     ts->pms = pkgmark_set_new(1024, 0);
+
+    ts->pkgs_installed = pkgs_array_new(16);
+    ts->pkgs_removed   = pkgs_array_new(16);
     return 1;
 }
 
-
-void poldek_ts_destroy(struct poldek_ts *ts)
+static void poldek_ts_destroy(struct poldek_ts *ts)
 {
     ts->_flags = 0;
     ts->ctx = NULL;
@@ -312,30 +319,20 @@
     n_cfree(&ts->dumpfile);
     n_cfree(&ts->prifile);
     
-    if (ts->rpmopts)
-        n_array_free(ts->rpmopts);
-
-    if (ts->rpmacros)
-        n_array_free(ts->rpmacros);
+    n_array_cfree(&ts->rpmopts);
+    n_array_cfree(&ts->rpmacros);
+    n_array_cfree(&ts->hold_patterns);
+    n_array_cfree(&ts->ign_patterns);
+    n_array_cfree(&ts->exclude_path);
 
-    if (ts->hold_patterns)
-        n_array_free(ts->hold_patterns);
-
-    if (ts->ign_patterns)
-        n_array_free(ts->ign_patterns);
-
-    if (ts->exclude_path)
-        n_array_free(ts->exclude_path);
-
-    ts->rpmopts = NULL;
-    ts->rpmacros = NULL;
-    ts->hold_patterns = ts->ign_patterns = NULL;
     if (ts->pm_pdirsrc)
         source_free(ts->pm_pdirsrc);
 
     if (ts->pms)
         pkgmark_set_free(ts->pms);
-    
+
+    n_array_cfree(&ts->pkgs_installed);
+    n_array_cfree(&ts->pkgs_removed);
     n_alloc_free(ts->_na);
 }
 
@@ -575,26 +572,6 @@
                       ts->pm_pdirsrc ? ts->pm_pdirsrc : NULL, NULL);
 }
 
-void poldek_iinf_init(struct poldek_iinf *iinf) 
-{
-    iinf->installed_pkgs = pkgs_array_new(16);
-    iinf->uninstalled_pkgs = pkgs_array_new(16);
-}
-
-void poldek_iinf_destroy(struct poldek_iinf *iinf) 
-{
-    if (iinf->installed_pkgs) {
-        n_array_free(iinf->installed_pkgs);
-        iinf->installed_pkgs = NULL;
-    }
-    
-    if (iinf->uninstalled_pkgs) {
-        n_array_free(iinf->uninstalled_pkgs);
-        iinf->uninstalled_pkgs = NULL;
-    }
-}
-
-
 int poldek_ts_add_pkg(struct poldek_ts *ts, struct pkg *pkg)
 {
     return arg_packages_add_pkg(ts->aps, pkg);
@@ -769,7 +746,7 @@
     return 1;
 }
 
-static int ts_prerun(struct poldek_ts *ts, struct poldek_iinf *iinf) 
+static int ts_prerun(struct poldek_ts *ts) 
 {
     int rc = 1;
 
@@ -813,8 +790,8 @@
     
     if (rc) {
         rc = arg_packages_setup(ts->aps, ts->pmctx);
-        if (rc && iinf)
-            poldek_iinf_init(iinf);
+        n_array_clean(ts->pkgs_installed);
+        n_array_clean(ts->pkgs_removed);
     }
 
     return rc;
@@ -995,10 +972,9 @@
     return rc;
 }
 
-extern int in_do_ts_install(struct poldek_ts *ts, struct poldek_iinf *iinf);
+extern int in_do_ts_install(struct poldek_ts *ts);
 
-static        
-int ts_run_install(struct poldek_ts *ts, struct poldek_iinf *iinf) 
+static int ts_run_install(struct poldek_ts *ts) 
 {
     int rc;
     
@@ -1027,11 +1003,10 @@
 
     if (ts->ctx->_depengine == 3) { /* hope, soon */
         msgn(5, "Running poldek3 dependency engine...");
-        //rc = in_do_poldek_ts_install(ts, iinf);
         n_die("Not implemented yet");
 
     } else {
-        rc = in_do_poldek_ts_install(ts, iinf);
+        rc = in_do_poldek_ts_install(ts);
     }
 
     if (rc && !ts->getop(ts, POLDEK_OP_RPMTEST))
@@ -1044,7 +1019,7 @@
 
 
 static
-int ts_run_uninstall(struct poldek_ts *ts, struct poldek_iinf *iinf) 
+int ts_run_uninstall(struct poldek_ts *ts) 
 {
     int rc;
 
@@ -1055,7 +1030,7 @@
         return 0;
     pkgdb_tx_commit(ts->db);
     
-    rc = do_poldek_ts_uninstall(ts, iinf);
+    rc = do_poldek_ts_uninstall(ts);
     
     if (rc && !ts->getop(ts, POLDEK_OP_TEST))
         pkgdb_tx_commit(ts->db);
@@ -1069,19 +1044,19 @@
 }
 
 static
-int ts_run_verify(struct poldek_ts *ts, void *foo) 
+int ts_run_verify(struct poldek_ts *ts) 
 {
     tn_array *pkgs = NULL;
     int nerr = 0, rc = 1;
 
     DBGF("%p\n", ts);
     //n_assert(poldek_ts_issetf(ts, POLDEK_TS_VERIFY));
-    foo = foo;
+
     if (poldek_ts_get_arg_count(ts) == 0) {
         poldek_load_sources(ts->ctx);
         
     } else {
-        if (!ts_prerun(ts, NULL))
+        if (!ts_prerun(ts))
             return 0;
     
         if (!poldek_load_sources(ts->ctx))
@@ -1157,12 +1132,15 @@
 
 
 
-int poldek_ts_run(struct poldek_ts *ts, struct poldek_iinf *iinf)
+int poldek_ts_run(struct poldek_ts *ts, unsigned flags)
 {
     struct ts_run *ts_run = NULL;
     int i = 0;
 
+    poldek_ts_setf(ts, flags);
     n_assert(ts->type);
+
+    
     DBGF("%d(%s)\n", ts->type, ts->typenam);
     while (ts_run_tbl[i].type) {
         if (ts_run_tbl[i].type == ts->type) {
@@ -1180,9 +1158,9 @@
         poldek_load_sources(ts->ctx);
 
     if ((ts_run->flags & TS_RUN_NOPRERUN) == 0)
-        if (!ts_prerun(ts, iinf))
+        if (!ts_prerun(ts))
             return 0;
         
-    return ts_run->run(ts, iinf);
+    return ts_run->run(ts);
 }
 

================================================================
Index: poldek/poldek/poldek_ts.h
diff -u poldek/poldek/poldek_ts.h:1.38 poldek/poldek/poldek_ts.h:1.39
--- poldek/poldek/poldek_ts.h:1.38	Thu Jun 21 18:47:45 2007
+++ poldek/poldek/poldek_ts.h	Fri Jun 29 00:28:21 2007
@@ -16,6 +16,10 @@
 
     POLDEK_TS_UPGRADEDIST  = POLDEK_TS_UPGRADE | POLDEK_TS_DIST,
     POLDEK_TS_INSTALLDIST  = POLDEK_TS_DIST,
+
+    POLDEK_TS_TRACK        = (1 << 10) /* track changes made by ts
+                                          (pkgs_{installed, removed})
+                                       */
 };
 
 enum poldek_ts_type {
@@ -117,16 +121,19 @@
     tn_array           *hold_patterns;
     tn_array           *ign_patterns; 
     tn_array           *exclude_path;
+
+    tn_array            *pkgs_installed; /* packages installed by transaction */
+    tn_array            *pkgs_removed;   /* packages removed by transaction */
     
     int  (*askpkg_fn)(const char *, struct pkg **pkgs, struct pkg *deflt);
     int  (*ask_fn)(int default_a, const char *, ...);
 
     tn_alloc           *_na;
     uint32_t           _flags;      /* POLDEK_TS_* */
-    uint32_t           _iflags;    /* internal flags */
-    uint32_t           _opvect[4];
-    uint32_t           _opvect_setmark[4];
-    uint32_t           _opvect_preserve[4];
+    uint32_t           _iflags;     /* internal flags */
+    uint32_t           _opvect[4];  /* options POLDEK_OP* */
+    uint32_t           _opvect_touched[4];
+    
     int   (*getop)(const struct poldek_ts *, int op);
     int   (*getop_v)(const struct poldek_ts *, int op, ...);
     void  (*setop)(struct poldek_ts *, int op, int onoff);
@@ -139,9 +146,6 @@
 struct poldek_ts *poldek_ts_new(struct poldek_ctx *ctx, unsigned flags);
 void poldek_ts_free(struct poldek_ts *ts);
 
-int poldek_ts_init(struct poldek_ts *ts, struct poldek_ctx *ctx);
-void poldek_ts_destroy(struct poldek_ts *ts);
-
 int poldek_ts_type(struct poldek_ts *ts);
 int poldek_ts_set_type(struct poldek_ts *ts, enum poldek_ts_type type,
                        const char *typenam);
@@ -173,20 +177,6 @@
 tn_array* poldek_ts_get_args_asmasks(struct poldek_ts *ts, int hashed);
 int poldek_ts_get_arg_count(struct poldek_ts *ts);
 
-struct poldek_iinf {            /* install info struct */
-    tn_array *installed_pkgs;
-    tn_array *uninstalled_pkgs;
-};
-
-void poldek_iinf_init(struct poldek_iinf *iinf);
-void poldek_iinf_destroy(struct poldek_iinf *iinf);
-
-int poldek_ts_run(struct poldek_ts *ts, struct poldek_iinf *iinf);
-
-//struct pkgdir;
-//struct pkgdir *poldek_ts_load_dest_pkgdir(struct poldek_ts *ts);
-//int poldek_ts_do_install_dist(struct poldek_ts *ts);
-//int poldek_ts_do_install(struct poldek_ts *ts, struct poldek_iinf *iinf);
-//int poldek_ts_do_uninstall(struct poldek_ts *ts, struct poldek_iinf *iinf);
+int poldek_ts_run(struct poldek_ts *ts, unsigned flags);
 
 #endif

================================================================
Index: poldek/poldek/uninstall.c
diff -u poldek/poldek/uninstall.c:1.42 poldek/poldek/uninstall.c:1.43
--- poldek/poldek/uninstall.c:1.42	Tue Jun 19 23:03:32 2007
+++ poldek/poldek/uninstall.c	Fri Jun 29 00:28:21 2007
@@ -51,7 +51,8 @@
 
 static void print_summary(tn_array *pkgs, struct pkgmark_set *pms, int ndep,
                           int simple);
-static void update_poldek_iinf(struct poldek_iinf *iinf, tn_array *pkgs,
+
+static void update_iinf(struct poldek_ts *ts, tn_array *pkgs,
                                struct pkgdb *db, int vrfy);
 struct uninstall_ctx *uctx;
 static int process_package(int indent, struct uninstall_ctx *uctx,
@@ -613,7 +614,7 @@
 }
 
 
-int do_poldek_ts_uninstall(struct poldek_ts *ts, struct poldek_iinf *iinf)
+int do_poldek_ts_uninstall(struct poldek_ts *ts)
 {
     int               nerr = 0, run_uninstall = 0;
     tn_array          *pkgs = NULL, *ordered_pkgs = NULL;
@@ -678,8 +679,8 @@
             vrfy = 1;
         }
             
-        if (iinf)
-            update_poldek_iinf(iinf, pkgs, ts->db, vrfy);
+        if (poldek_ts_issetf(ts, POLDEK_TS_TRACK))
+            update_iinf(ts, pkgs, ts->db, vrfy);
     }
 
  l_end:
@@ -717,8 +718,8 @@
 
 
 static
-void update_poldek_iinf(struct poldek_iinf *iinf, tn_array *pkgs,
-                        struct pkgdb *db, int vrfy)
+void update_iinf(struct poldek_ts *ts, tn_array *pkgs, struct pkgdb *db,
+                 int vrfy)
 {
     int i, is_installed = 0;
     
@@ -734,7 +735,7 @@
             is_installed = pkgdb_is_pkg_installed(db, pkg, NULL);
         
         if (!is_installed)
-            n_array_push(iinf->uninstalled_pkgs, pkg_link(pkg));
+            n_array_push(ts->pkgs_removed, pkg_link(pkg));
     }
     
     if (vrfy) 

================================================================
Index: poldek/poldek/upgrade-dist.c
diff -u poldek/poldek/upgrade-dist.c:1.4 poldek/poldek/upgrade-dist.c:1.5
--- poldek/poldek/upgrade-dist.c:1.4	Tue Jun 19 22:39:45 2007
+++ poldek/poldek/upgrade-dist.c	Fri Jun 29 00:28:21 2007
@@ -49,7 +49,7 @@
 int process_pkg(const struct pkg *dbpkg, struct poldek_ts *ts,
                 tn_hash *marked_h, int *nmarked)
 {
-    struct pkg *pkg, *tmpkg;
+    struct pkg *pkg = NULL, *tmpkg;
     char pkgkey[256];
     int i, cmprc;
 
@@ -166,5 +166,5 @@
     if (nmarked == 0)
         msgn(1, _("Nothing to do"));
 
-    return in_do_poldek_ts_install(ts, NULL);
+    return in_do_poldek_ts_install(ts);
 }

================================================================
Index: poldek/poldek/cli/cli.c
diff -u poldek/poldek/cli/cli.c:1.40 poldek/poldek/cli/cli.c:1.41
--- poldek/poldek/cli/cli.c:1.40	Thu Jun 21 18:47:45 2007
+++ poldek/poldek/cli/cli.c	Fri Jun 29 00:28:21 2007
@@ -723,19 +723,16 @@
     return do_poclidek_exec(cctx, ts, argc, argv, NULL);
 }
 
-void poclidek_apply_iinf(struct poclidek_ctx *cctx, struct poldek_iinf *iinf)
+void poclidek_apply_iinf(struct poclidek_ctx *cctx, struct poldek_ts *ts)
 {
     int i, n = 0;
     struct pkg_dent *ent = NULL;
     
-    if (iinf == NULL || cctx->pkgs_installed == NULL)
-        return;
-    
     if (cctx->rootdir)
         ent = poclidek_dent_find(cctx, POCLIDEK_INSTALLEDDIR);
 
-    for (i=0; i < n_array_size(iinf->uninstalled_pkgs); i++) {
-        struct pkg *pkg = n_array_nth(iinf->uninstalled_pkgs, i);
+    for (i=0; i < n_array_size(ts->pkgs_removed); i++) {
+        struct pkg *pkg = n_array_nth(ts->pkgs_removed, i);
 
         pkgdir_remove_package(cctx->dbpkgdir, pkg);
         if (ent)
@@ -745,8 +742,8 @@
         DBGF("- %s\n", pkg_id(pkg));
     }
 
-    for (i=0; i < n_array_size(iinf->installed_pkgs); i++) {
-        struct pkg *pkg = n_array_nth(iinf->installed_pkgs, i);
+    for (i=0; i < n_array_size(ts->pkgs_installed); i++) {
+        struct pkg *pkg = n_array_nth(ts->pkgs_installed, i);
 
         /*
           assure new packages haven't recno and clean it if they have;

================================================================
Index: poldek/poldek/cli/cli.h
diff -u poldek/poldek/cli/cli.h:1.16 poldek/poldek/cli/cli.h:1.17
--- poldek/poldek/cli/cli.h:1.16	Thu May 19 16:04:49 2005
+++ poldek/poldek/cli/cli.h	Fri Jun 29 00:28:21 2007
@@ -23,11 +23,9 @@
 #define OPT_GID_OP_SPLIT      (1400 + OPT_GID_BASE)
 #define OPT_GID_OP_OTHER      (1600 + OPT_GID_BASE)
 
-
 int poclidek_load_aliases(struct poclidek_ctx *cctx, const char *path);
 
-struct poldek_iinf;
-void poclidek_apply_iinf(struct poclidek_ctx *cctx, struct poldek_iinf *iinf);
+void poclidek_apply_iinf(struct poclidek_ctx *cctx, struct poldek_ts *ts);
 
 int poclidek_save_installedcache(struct poclidek_ctx *cctx,
                                  struct pkgdir *pkgdir);

================================================================
Index: poldek/poldek/cli/install.c
diff -u poldek/poldek/cli/install.c:1.43 poldek/poldek/cli/install.c:1.44
--- poldek/poldek/cli/install.c:1.43	Sun Jun 17 22:09:12 2007
+++ poldek/poldek/cli/install.c	Fri Jun 29 00:28:21 2007
@@ -539,9 +539,8 @@
 
 static int install(struct cmdctx *cmdctx)
 {
-    struct poldek_iinf   iinf;
     struct poclidek_ctx  *cctx;
-    struct poldek_ts      *ts;
+    struct poldek_ts     *ts;
     int rc = 1, is_test;
     
     cctx = cmdctx->cctx;
@@ -552,16 +551,13 @@
         poldek_ts_setf(ts, POLDEK_TS_UPGRADE); /* the default */
     is_test = ts->getop_v(ts, POLDEK_OP_TEST, POLDEK_OP_RPMTEST, 0);
 
-    rc = poldek_ts_run(ts, is_test ? NULL : &iinf);
+    rc = poldek_ts_run(ts, is_test ? 0 : POLDEK_TS_TRACK);
     
     if (rc == 0 && !sigint_reached())
         msgn(1, _("There were errors"));
     
     if (!is_test && cmdctx->cctx->pkgs_installed)
-        poclidek_apply_iinf(cmdctx->cctx, &iinf);
-    
-    if (!is_test)
-        poldek_iinf_destroy(&iinf);
+        poclidek_apply_iinf(cmdctx->cctx, ts);
     
     return rc;
 }
@@ -583,6 +579,6 @@
         }
     }
 
-    rc = poldek_ts_run(rt->ts, NULL);
+    rc = poldek_ts_run(rt->ts, 0);
     return rc ? OPGROUP_RC_OK : OPGROUP_RC_ERROR;
 }

================================================================
Index: poldek/poldek/cli/op_verify.c
diff -u poldek/poldek/cli/op_verify.c:1.16 poldek/poldek/cli/op_verify.c:1.17
--- poldek/poldek/cli/op_verify.c:1.16	Sun May 20 23:44:28 2007
+++ poldek/poldek/cli/op_verify.c	Fri Jun 29 00:28:21 2007
@@ -240,6 +240,6 @@
         return OPGROUP_RC_NIL;
 
     poldek_ts_set_type(rt->ts, POLDEK_TS_VERIFY, "verify");
-    return poldek_ts_run(rt->ts, NULL) ? OPGROUP_RC_OK : OPGROUP_RC_ERROR;
+    return poldek_ts_run(rt->ts, 0) ? OPGROUP_RC_OK : OPGROUP_RC_ERROR;
 }
 

================================================================
Index: poldek/poldek/cli/uninstall.c
diff -u poldek/poldek/cli/uninstall.c:1.30 poldek/poldek/cli/uninstall.c:1.31
--- poldek/poldek/cli/uninstall.c:1.30	Tue Jun 19 16:22:52 2007
+++ poldek/poldek/cli/uninstall.c	Fri Jun 29 00:28:21 2007
@@ -227,9 +227,9 @@
 {
     struct poclidek_ctx  *cctx;
     struct poldek_ts     *ts;
-    struct poldek_iinf   iinf, *iinfp;
     tn_array             *pkgs;
     int                  i, err = 0;
+    unsigned             ts_flags = 0;
     
     cctx = cmdctx->cctx;
     ts = cmdctx->ts;
@@ -258,20 +258,16 @@
         poldek_ts_add_pkg(ts, n_array_nth(pkgs, i));
     }
     n_array_free(pkgs);
-
-    if (ts->getop_v(ts, POLDEK_OP_TEST, POLDEK_OP_RPMTEST, 0))
-        iinfp = NULL;
-    else
<<Diff was trimmed, longer than 597 lines>>

---- CVS-web:
    http://cvs.pld-linux.org/poldek/poldek/configure.in?r1=1.139&r2=1.140&f=u
    http://cvs.pld-linux.org/poldek/poldek/libpoldek.sym?r1=1.27&r2=1.28&f=u
    http://cvs.pld-linux.org/poldek/poldek/poldek_ts.c?r1=1.64&r2=1.65&f=u
    http://cvs.pld-linux.org/poldek/poldek/poldek_ts.h?r1=1.38&r2=1.39&f=u
    http://cvs.pld-linux.org/poldek/poldek/uninstall.c?r1=1.42&r2=1.43&f=u
    http://cvs.pld-linux.org/poldek/poldek/upgrade-dist.c?r1=1.4&r2=1.5&f=u
    http://cvs.pld-linux.org/poldek/poldek/cli/cli.c?r1=1.40&r2=1.41&f=u
    http://cvs.pld-linux.org/poldek/poldek/cli/cli.h?r1=1.16&r2=1.17&f=u
    http://cvs.pld-linux.org/poldek/poldek/cli/install.c?r1=1.43&r2=1.44&f=u
    http://cvs.pld-linux.org/poldek/poldek/cli/op_verify.c?r1=1.16&r2=1.17&f=u
    http://cvs.pld-linux.org/poldek/poldek/cli/uninstall.c?r1=1.30&r2=1.31&f=u
    http://cvs.pld-linux.org/poldek/poldek/install/install.c?r1=1.8&r2=1.9&f=u
    http://cvs.pld-linux.org/poldek/poldek/install/install.h?r1=1.2&r2=1.3&f=u



More information about the pld-cvs-commit mailing list