Mailinglist Archive: zypp-commit (223 mails)

< Previous Next >
[zypp-commit] r10510 - in /branches/SuSE-SLE-10-SP2-Branch/zypper/src: zmart-misc.cc zmart.h
  • From: jkupec@xxxxxxxxxxxxxxxx
  • Date: Mon, 07 Jul 2008 13:29:32 -0000
  • Message-id: <20080707132932.B7DEA2C15B@xxxxxxxxxxxxxxxx>
Author: jkupec
Date: Mon Jul 7 15:29:32 2008
New Revision: 10510

URL: http://svn.opensuse.org/viewcvs/zypp?rev=10510&view=rev
Log:
- exit in non-interactive mode if given package cannot be found
(bnc #403216)

Modified:
branches/SuSE-SLE-10-SP2-Branch/zypper/src/zmart-misc.cc
branches/SuSE-SLE-10-SP2-Branch/zypper/src/zmart.h

Modified: branches/SuSE-SLE-10-SP2-Branch/zypper/src/zmart-misc.cc
URL:
http://svn.opensuse.org/viewcvs/zypp/branches/SuSE-SLE-10-SP2-Branch/zypper/src/zmart-misc.cc?rev=10510&r1=10509&r2=10510&view=diff
==============================================================================
--- branches/SuSE-SLE-10-SP2-Branch/zypper/src/zmart-misc.cc (original)
+++ branches/SuSE-SLE-10-SP2-Branch/zypper/src/zmart-misc.cc Mon Jul 7
15:29:32 2008
@@ -137,6 +137,10 @@
cerr_vv << "... done" << endl;
if (!installer.item) {
cerr << kind << " '" << name << "' " << _("not found") << endl;
+ if (gSettings.non_interactive)
+ exit(ZYPPER_EXIT_INF_CAP_NOT_FOUND); // bnc #403216
+ else
+ WAR << kind << " '" << name << "' " << _("not found") << endl;
return; //error?
}

@@ -190,7 +194,11 @@
);
cerr_vv << "... done" << endl;
if (!deleter.found) {
- cerr << _("Not found") << endl;
+ cerr << kind << " '" << name << "' " << _("not found") << endl;
+ if (gSettings.non_interactive)
+ exit(ZYPPER_EXIT_INF_CAP_NOT_FOUND); // bnc #403216
+ else
+ WAR << kind << " '" << name << "' " << _("not found") << endl;
return; //error?
}
}

Modified: branches/SuSE-SLE-10-SP2-Branch/zypper/src/zmart.h
URL:
http://svn.opensuse.org/viewcvs/zypp/branches/SuSE-SLE-10-SP2-Branch/zypper/src/zmart.h?rev=10510&r1=10509&r2=10510&view=diff
==============================================================================
--- branches/SuSE-SLE-10-SP2-Branch/zypper/src/zmart.h (original)
+++ branches/SuSE-SLE-10-SP2-Branch/zypper/src/zmart.h Mon Jul 7 15:29:32 2008
@@ -42,6 +42,7 @@
#define ZYPPER_EXIT_INF_SEC_UPDATE_NEEDED 101 // security update needed
#define ZYPPER_EXIT_INF_REBOOT_NEEDED 102 // reboot needed after
install/upgrade
#define ZYPPER_EXIT_INF_RESTART_NEEDED 103 // restart of package manager
itself needed
+#define ZYPPER_EXIT_INF_CAP_NOT_FOUND 104 // given capability not found
(for install/remove)

struct Settings
{

--
To unsubscribe, e-mail: zypp-commit+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: zypp-commit+help@xxxxxxxxxxxx

< Previous Next >
This Thread
  • No further messages