summaryrefslogtreecommitdiffstats
path: root/usr.bin
diff options
context:
space:
mode:
authormike <mike@FreeBSD.org>2002-03-20 08:59:20 +0000
committermike <mike@FreeBSD.org>2002-03-20 08:59:20 +0000
commit54e30b41907dbbf0b3c62cc2ea9d3322eb451019 (patch)
tree9e6b8be6c284393039eef48990d1e24ad65d8b7d /usr.bin
parent1156d9dd5939faa4e583138a2cddeabb6cb9b808 (diff)
downloadFreeBSD-src-54e30b41907dbbf0b3c62cc2ea9d3322eb451019.zip
FreeBSD-src-54e30b41907dbbf0b3c62cc2ea9d3322eb451019.tar.gz
When invoked with no file arguments, display usage.
Submitted by: Tim J. Robbins <tim@robbins.dropbear.id.au> PR: 36074 Use new ID scheme.
Diffstat (limited to 'usr.bin')
-rw-r--r--usr.bin/paste/paste.c11
1 files changed, 7 insertions, 4 deletions
diff --git a/usr.bin/paste/paste.c b/usr.bin/paste/paste.c
index a197119..cad7bef 100644
--- a/usr.bin/paste/paste.c
+++ b/usr.bin/paste/paste.c
@@ -40,13 +40,14 @@ static const char copyright[] =
The Regents of the University of California. All rights reserved.\n";
#endif /* not lint */
-#ifndef lint
#if 0
+#ifndef lint
static char sccsid[] = "@(#)paste.c 8.1 (Berkeley) 6/6/93";
-#endif
-static const char rcsid[] =
- "$FreeBSD$";
#endif /* not lint */
+#endif
+
+#include <sys/cdefs.h>
+__FBSDID("$FreeBSD$");
#include <sys/types.h>
#include <err.h>
@@ -88,6 +89,8 @@ main(argc, argv)
argc -= optind;
argv += optind;
+ if (*argv == NULL)
+ usage();
if (!delim) {
delimcnt = 1;
delim = "\t";
OpenPOWER on IntegriCloud