(enter_command_line_file): Barf if NAME is "".
authorRoland McGrath <roland@redhat.com>
Tue, 10 Oct 1995 18:59:08 +0000 (18:59 +0000)
committerRoland McGrath <roland@redhat.com>
Tue, 10 Oct 1995 18:59:08 +0000 (18:59 +0000)
main.c

diff --git a/main.c b/main.c
index 4cfb4d7edce2abc901db8cea4a1ef9b1ce8b5a08..17cdb5c9aceafa86d63071cc2d8a50f3689c3d41 100644 (file)
--- a/main.c
+++ b/main.c
@@ -367,6 +367,9 @@ static struct file *
 enter_command_line_file (name)
      char *name;
 {
+  if (name[0] == '\0')
+    fatal ("empty string invalid as file name");
+
   if (name[0] == '~')
     {
       char *expanded = tilde_expand (name);