aboutsummaryrefslogtreecommitdiff
path: root/toys
diff options
context:
space:
mode:
authorRob Landley <rob@landley.net>2013-12-22 20:15:54 -0600
committerRob Landley <rob@landley.net>2013-12-22 20:15:54 -0600
commit5a73f3992d75dd4c7beefae2fa8a843d14372b19 (patch)
treef2ed4feaeca0d082c4b1475fcd602e7d760c9815 /toys
parentf070ec01d918ff0474a0a5fc9aa745fcd848622a (diff)
downloadtoybox-5a73f3992d75dd4c7beefae2fa8a843d14372b19.tar.gz
Ashwini sharma pointed out that show_help() doesn't exit so "ifconfig eth0 netmask" would segfault. Replace it with an error_exit(), see list for aesthetic issue this raises re: help text.
Diffstat (limited to 'toys')
-rw-r--r--toys/other/ifconfig.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/toys/other/ifconfig.c b/toys/other/ifconfig.c
index 38d2f64b..59d1574d 100644
--- a/toys/other/ifconfig.c
+++ b/toys/other/ifconfig.c
@@ -478,7 +478,7 @@ void ifconfig_main(void)
// Is this an SIOCSI entry?
if ((off|0xff) == 0x89ff) {
if (!rev) {
- if (!*++argv) show_help();
+ if (!*++argv) error_exit("%s needs argument", t->name);
// Assign value to ifre field and call ioctl? (via IFREQ_OFFSZ.)
if (on < 0) {