[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#507952: marked as done (picp: inappropriate exit status on some failure types)

Your message dated Sun, 20 Feb 2011 01:22:12 +0000
with message-id <E1Pqy04-0003Wc-Ab@franck.debian.org>
and subject line Bug#472734: Removed package(s) from unstable
has caused the Debian Bug report #507952,
regarding picp: inappropriate exit status on some failure types
to be marked as done.

This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.

(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact owner@bugs.debian.org

507952: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=507952
Debian Bug Tracking System
Contact owner@bugs.debian.org with problems
--- Begin Message ---
Package: picp
Version: 0.6.7-3
Severity: normal
Tags: patch

When picp encounters some types of errors, such as finding CTS deasserted
(implying that there is no programmer hooked up to the other end of the serial
line), it reports the error to standard error correctly, but then exits with
a zero status, indicating success.  This does not seem correct.  A patch is
attached that attempts to correct this problem, though it is a fairly quick
patch and should be reviewed more thoroughly by the maintainer before applying.
This patch also causes picp to exit with a nonzero status when receiving an
interrupt signal, and changes a strange exit(1) line in main() to more closely
conform to the error propagation style of the rest of main.c.  Apply with
[patch -p1] in the picp-0.6.7 directory.

-- System Information:
Debian Release: lenny/sid
  APT prefers unstable
  APT policy: (990, 'unstable')
Architecture: amd64 (x86_64)

Kernel: Linux (SMP w/2 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash

Versions of packages picp depends on:
ii  libc6                         2.7-16     GNU C Library: Shared libraries

picp recommends no packages.

picp suggests no packages.

-- no debconf information
diff -ur picp-0.6.7.old/main.c picp-0.6.7.new/main.c
--- picp-0.6.7.old/main.c	2008-12-05 22:40:18.000000000 -0600
+++ picp-0.6.7.new/main.c	2008-12-05 22:40:03.000000000 -0600
@@ -223,7 +223,7 @@
 	fprintf(stderr, "exiting...\n");
-	exit(0);
+	exit(1);
@@ -3420,10 +3420,10 @@
 								fprintf(stderr, " programmer\n\n");
-								exit(1);
+								fail = true;
-							if (DoInitPIC(picDevice))					// try to load up the parameters for this device
+							if (!fail && DoInitPIC(picDevice))					// try to load up the parameters for this device
 								while (argc && !fail)					// do as long as we can read some more
@@ -3467,6 +3467,7 @@
 													fprintf(stderr, " programmer does not support ISP programming\n");
+													fail = true;
 													ISPflag = true;
@@ -3499,32 +3500,49 @@
 												fprintf(stderr, "bad argument: '%s'\n", *(argv - 1));	// back up, show the trouble spot
+												fail = true;
-							else		// DoInitPIC failed
+							else if (!fail)		// DoInitPIC failed
+							{
 								fprintf(stderr, "failed to initialize %s\n", picDevice->name);
+								fail = true;
+							}
+						{
 							fprintf(stderr, "failed to obtain programmer firmware version number\n");
+							fail = true;
+						}
+					{
 						fprintf(stderr, "failed to connect to programmer\n");
+						fail = true;
+					}
+				{
 					fprintf(stderr, "failed to set up the serial port\n");
+					fail = true;
+				}
+			{
 				fprintf(stderr, "failed to open device '%s'\n", deviceName);
+				fail = true;
+			}
 			fprintf(stderr, "unrecognized PIC device type: '%s'\n", picName);		// don't know that one;
 			ShowDevices();														// give a helpful list of supported devices
+			fail = true;
Only in picp-0.6.7.new: main.c.~1~

--- End Message ---
--- Begin Message ---
Version: 0.6.8-1+rm

Dear submitter,

as the package picp has just been removed from the Debian archive
unstable we hereby close the associated bug reports.  We are sorry
that we couldn't deal with your issue properly.

For details on the removal, please see http://bugs.debian.org/472734

The version of this package that was in Debian prior to this removal
can still be found using http://snapshot.debian.org/.

This message was generated automatically; if you believe that there is
a problem with it please contact the archive administrators by mailing

Debian distribution maintenance software
Luca Falavigna (the ftpmaster behind the curtain)

--- End Message ---

Reply to: