From: millert Date: Sat, 5 Apr 1997 22:51:53 +0000 (+0000) Subject: Fix bug introduced with "exit(0) if no files" behavior change. X-Git-Url: http://artulab.com/gitweb/?a=commitdiff_plain;h=e19eb45d2ee8ca75aad5019c3c42d33a9e69e9d1;p=openbsd Fix bug introduced with "exit(0) if no files" behavior change. --- diff --git a/bin/pax/options.c b/bin/pax/options.c index 23ae6cf9927..ec4324c6da4 100644 --- a/bin/pax/options.c +++ b/bin/pax/options.c @@ -1,4 +1,4 @@ -/* $OpenBSD: options.c,v 1.20 1997/04/05 22:36:14 millert Exp $ */ +/* $OpenBSD: options.c,v 1.21 1997/04/05 22:51:53 millert Exp $ */ /* $NetBSD: options.c,v 1.6 1996/03/26 23:54:18 mrg Exp $ */ /*- @@ -42,7 +42,7 @@ #if 0 static char sccsid[] = "@(#)options.c 8.2 (Berkeley) 4/18/94"; #else -static char rcsid[] = "$OpenBSD: options.c,v 1.20 1997/04/05 22:36:14 millert Exp $"; +static char rcsid[] = "$OpenBSD: options.c,v 1.21 1997/04/05 22:51:53 millert Exp $"; #endif #endif /* not lint */ @@ -794,7 +794,7 @@ tar_options(argc, argv) argv += optind; /* Traditional tar behaviour (pax wants to read filelist from stdin) */ - if (argc == 0) + if ((act == ARCHIVE || act == APPND) && argc == 0) exit(0); /*