aboutsummaryrefslogtreecommitdiff
path: root/shell
diff options
context:
space:
mode:
authorDenis Vlasenko <vda.linux@googlemail.com>2008-03-24 00:04:42 +0000
committerDenis Vlasenko <vda.linux@googlemail.com>2008-03-24 00:04:42 +0000
commit0b6c6a9c9f555a33d681290cce77510460457c03 (patch)
tree0d5f95c0cc0a2f6945aa97fa50266e8b8288da75 /shell
parenta79428998d76c1758ca12546e5db945a0cd64518 (diff)
downloadbusybox-w32-0b6c6a9c9f555a33d681290cce77510460457c03.tar.gz
busybox-w32-0b6c6a9c9f555a33d681290cce77510460457c03.tar.bz2
busybox-w32-0b6c6a9c9f555a33d681290cce77510460457c03.zip
lpd: fix OOM vulnerability (was eating arbitrarily large commands)
Diffstat (limited to 'shell')
-rw-r--r--shell/hush.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/shell/hush.c b/shell/hush.c
index eb0633b18..545367cb6 100644
--- a/shell/hush.c
+++ b/shell/hush.c
@@ -1061,7 +1061,7 @@ static int builtin_read(char **argv)
1061 char *string; 1061 char *string;
1062 const char *name = argv[1] ? argv[1] : "REPLY"; 1062 const char *name = argv[1] ? argv[1] : "REPLY";
1063 1063
1064 string = xmalloc_reads(STDIN_FILENO, xasprintf("%s=", name)); 1064 string = xmalloc_reads(STDIN_FILENO, xasprintf("%s=", name), NULL);
1065 return set_local_var(string, 0); 1065 return set_local_var(string, 0);
1066} 1066}
1067 1067