changeset 7528:9b2c273b91af

(main): Avoid crash if argc is 1.
author Richard M. Stallman <rms@gnu.org>
date Tue, 17 May 1994 19:12:55 +0000
parents 1f09079e18c4
children e326ef45f084
files lib-src/b2m.c
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lib-src/b2m.c	Tue May 17 09:48:53 1994 +0000
+++ b/lib-src/b2m.c	Tue May 17 19:12:55 1994 +0000
@@ -50,7 +50,7 @@
   (stdout)->_flag &= ~_IOTEXT;
   (stdin)->_flag &= ~_IOTEXT;
 #endif
-  if (strcmp (argv[1], "--help") == 0)
+  if (argc >= 2 && strcmp (argv[1], "--help") == 0)
     {
       fprintf (stderr, "Usage: %s <babylmailbox >unixmailbox\n", argv[0]);
       exit (0);