summaryrefslogtreecommitdiff
path: root/shell
diff options
context:
space:
mode:
Diffstat (limited to 'shell')
-rw-r--r--shell/shell_common.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/shell/shell_common.c b/shell/shell_common.c
index 13163ac..1eca101 100644
--- a/shell/shell_common.c
+++ b/shell/shell_common.c
@@ -57,7 +57,7 @@ shell_builtin_read(struct builtin_read_params *params)
argv = params->argv;
pp = argv;
while (*pp) {
- if (endofname(*pp)[0] != '\0') {
+ if (!*pp[0] || endofname(*pp)[0] != '\0') {
/* Mimic bash message */
bb_error_msg("read: '%s': bad variable name", *pp);
return (const char *)(uintptr_t)1;