[BusyBox-cvs] busybox/archival bunzip2.c,1.15,1.16

Glenn McGrath bug1 at busybox.net
Wed Oct 29 03:37:56 UTC 2003


Update of /var/cvs/busybox/archival
In directory winder:/tmp/cvs-serv15751/archival

Modified Files:
	bunzip2.c 
Log Message:
Use the return value from uncompress_bunzip, fix some typo


Index: bunzip2.c
===================================================================
RCS file: /var/cvs/busybox/archival/bunzip2.c,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -d -r1.15 -r1.16
--- bunzip2.c	28 Oct 2003 23:04:50 -0000	1.15
+++ bunzip2.c	29 Oct 2003 03:37:52 -0000	1.16
@@ -83,16 +83,13 @@
 		dst_fd = bb_xopen(save_name, O_WRONLY | O_CREAT);
 	}
 
-	if (uncompressStream(src_fd, dst_fd) == 0) {
-		if (!(flags & bunzip_to_stdout)) {
-			delete_name = argv[optind];
-		}
-		status = EXIT_SUCCESS;
-	} else {
-		if (!(flags & bunzip_to_stdout)) {
+	status = uncompressStream(src_fd, dst_fd);
+	if(!(flags & bunzip_to_stdout)) {
+		if (status) {
 			delete_name = save_name;
+		} else {
+			delete_name = argv[optind];
 		}
-		status = EXIT_FAILURE;
 	}
 
 	if ((delete_name) && (unlink(delete_name) < 0)) {




More information about the busybox-cvs mailing list