Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/tests/lib/libcurses/director tests/libcurses: error out if c...
details: https://anonhg.NetBSD.org/src/rev/cd06664bea6d
branches: trunk
changeset: 951903:cd06664bea6d
user: rillig <rillig%NetBSD.org@localhost>
date: Sun Feb 07 13:56:23 2021 +0000
description:
tests/libcurses: error out if called with too many arguments
This helps against users who try to add more options after the first
non-option argument and wonder why these options are silently ignored.
diffstat:
tests/lib/libcurses/director/director.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diffs (18 lines):
diff -r 57d1a7ab65b6 -r cd06664bea6d tests/lib/libcurses/director/director.c
--- a/tests/lib/libcurses/director/director.c Sun Feb 07 13:44:22 2021 +0000
+++ b/tests/lib/libcurses/director/director.c Sun Feb 07 13:56:23 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: director.c,v 1.13 2021/02/07 13:44:22 rillig Exp $ */
+/* $NetBSD: director.c,v 1.14 2021/02/07 13:56:23 rillig Exp $ */
/*-
* Copyright 2009 Brett Lymn <blymn%NetBSD.org@localhost>
@@ -176,7 +176,7 @@
argc -= optind;
argv += optind;
- if (argc < 1)
+ if (argc != 1)
usage();
if (termpath == NULL)
Home |
Main Index |
Thread Index |
Old Index