aboutsummaryrefslogtreecommitdiff
path: root/networking/libiproute/iproute.c
diff options
context:
space:
mode:
authorBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2006-06-07 20:17:41 +0000
committerBernhard Reutner-Fischer <rep.dot.nop@gmail.com>2006-06-07 20:17:41 +0000
commit19008b83735341c91fa8a09a072ffe9816c9e423 (patch)
tree6e35288c247102998a775cbc16f9ec014e00e7fd /networking/libiproute/iproute.c
parent4c5ad2fc90389bf1239f17d84967d07b82f31dd7 (diff)
downloadbusybox-19008b83735341c91fa8a09a072ffe9816c9e423.tar.gz
- reuse strings and messages. Saves about 600B
Diffstat (limited to 'networking/libiproute/iproute.c')
-rw-r--r--networking/libiproute/iproute.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/networking/libiproute/iproute.c b/networking/libiproute/iproute.c
index 6052a3023..511e89107 100644
--- a/networking/libiproute/iproute.c
+++ b/networking/libiproute/iproute.c
@@ -343,14 +343,14 @@ static int iproute_modify(int cmd, unsigned flags, int argc, char **argv)
NEXT_ARG();
}
if (get_unsigned(&mtu, *argv, 0)) {
- invarg("\"mtu\" value is invalid\n", *argv);
+ invarg(*argv, "mtu");
}
rta_addattr32(mxrta, sizeof(mxbuf), RTAX_MTU, mtu);
} else if (matches(*argv, "protocol") == 0) {
uint32_t prot;
NEXT_ARG();
if (rtnl_rtprot_a2n(&prot, *argv))
- invarg("\"protocol\" value is invalid\n", *argv);
+ invarg(*argv, "protocol");
req.r.rtm_protocol = prot;
proto_ok =1;
} else if (strcmp(*argv, "dev") == 0 ||
@@ -487,7 +487,7 @@ static int iproute_list_or_flush(int argc, char **argv, int flush)
filter.tb = RT_TABLE_MAIN;
if (flush && argc <= 0) {
- fprintf(stderr, "\"ip route flush\" requires arguments.\n");
+ bb_error_msg(bb_msg_requires_arg, "\"ip route flush\"");
return -1;
}
@@ -498,7 +498,7 @@ static int iproute_list_or_flush(int argc, char **argv, int flush)
filter.protocolmask = -1;
if (rtnl_rtprot_a2n(&prot, *argv)) {
if (strcmp(*argv, "all") != 0) {
- invarg("invalid \"protocol\"\n", *argv);
+ invarg(*argv, "protocol");
}
prot = 0;
filter.protocolmask = 0;
@@ -541,7 +541,7 @@ static int iproute_list_or_flush(int argc, char **argv, int flush)
if (matches(*argv, "cache") == 0) {
filter.tb = -1;
} else if (matches(*argv, "main") != 0) {
- invarg("invalid \"table\"", *argv);
+ invarg(*argv, "table");
}
} else if (matches(*argv, "cache") == 0) {
filter.tb = -1;