Empty transaction is not an error (RhBug:699929)
authorPanu Matilainen <pmatilai@redhat.com>
Wed, 18 May 2011 05:28:07 +0000 (08:28 +0300)
committerPanu Matilainen <pmatilai@redhat.com>
Wed, 18 May 2011 05:28:07 +0000 (08:28 +0300)
- Empty transaction just means we have nothing at all to do,
  but it's not an actual error.

lib/transaction.c

index 3fd0279..84cc8e3 100644 (file)
@@ -1398,8 +1398,9 @@ int rpmtsRun(rpmts ts, rpmps okProbs, rpmprobFilterFlags ignoreSet)
     /* Force default 022 umask during transaction for consistent results */
     mode_t oldmask = umask(022);
 
-    /* XXX programmer error segfault avoidance. */
+    /* Empty transaction, nothing to do */
     if (rpmtsNElements(ts) <= 0) {
+       rc = 0;
        goto exit;
     }