Author: guillem
Date: 2006-05-30 23:19:40 +0000 (Tue, 30 May 2006)
New Revision: 356

Modified:
   trunk/ChangeLog
   trunk/debian/changelog
   trunk/src/enquiry.c
Log:
Print the bogus version and prefix the error message with 'dpkg: '
when using '--compare-versions'. Closes: #369177


Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog     2006-05-30 12:33:42 UTC (rev 355)
+++ trunk/ChangeLog     2006-05-30 23:19:40 UTC (rev 356)
@@ -1,3 +1,8 @@
+2006-05-31  Guillem Jover  <[EMAIL PROTECTED]>
+
+       * src/enquiry.c (cmpversions): Prefix the bad syntax error with a
+       'dpkg: ' and print the bogus version string.
+
 2006-05-25  Guillem Jover  <[EMAIL PROTECTED]>
 
        * scripts/install-info.pl: Exit if the lock file already exists.

Modified: trunk/debian/changelog
===================================================================
--- trunk/debian/changelog      2006-05-30 12:33:42 UTC (rev 355)
+++ trunk/debian/changelog      2006-05-30 23:19:40 UTC (rev 356)
@@ -66,6 +66,8 @@
     Based on patch by Ben Pfaff. Closes: #368874
   * Correct default info directory for '--infodir' in intall-info man
     page (Ben Pfaff). Closes: #368875
+  * Print the bogus version and prefix the error message with 'dpkg: '
+    when using '--compare-versions'. Closes: #369177
 
   [ Updated dpkg Translations ]
   * Portuguese (Miguel Figueiredo).

Modified: trunk/src/enquiry.c
===================================================================
--- trunk/src/enquiry.c 2006-05-30 12:33:42 UTC (rev 355)
+++ trunk/src/enquiry.c 2006-05-30 23:19:40 UTC (rev 356)
@@ -426,7 +426,8 @@
   if (*argv[0] && strcmp(argv[0],"<unknown>")) {
     emsg= parseversion(&a,argv[0]);
     if (emsg) {
-      if (printf(_("version a has bad syntax: %s\n"),emsg) == EOF) 
werr("stdout");
+      if (printf(_("dpkg: version '%s' has bad syntax: %s\n"), argv[0], emsg) 
== EOF)
+        werr("stdout");
       if (fflush(stdout)) werr("stdout");
       exit(1);
     }
@@ -436,7 +437,8 @@
   if (*argv[2] && strcmp(argv[2],"<unknown>")) {
     emsg= parseversion(&b,argv[2]);
     if (emsg) {
-      if (printf(_("version b has bad syntax: %s\n"),emsg) == EOF) 
werr("stdout");
+      if (printf(_("dpkg: version '%s' has bad syntax: %s\n"), argv[2], emsg) 
== EOF)
+        werr("stdout");
       if (fflush(stdout)) werr("stdout");
       exit(1);
     }


-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to