summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--shell/ash.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/shell/ash.c b/shell/ash.c
index c51fb80..3e9997b 100644
--- a/shell/ash.c
+++ b/shell/ash.c
@@ -8979,7 +8979,7 @@ mklocal(char *name)
*/
lvp = localvars;
while (lvp) {
- if (varcmp(lvp->vp->var_text, name) == 0) {
+ if (lvp->vp && varcmp(lvp->vp->var_text, name) == 0) {
if (eq)
setvareq(name, 0);
/* else: