diff options
author | Rob Landley <rob@landley.net> | 2015-11-08 00:32:30 -0600 |
---|---|---|
committer | Rob Landley <rob@landley.net> | 2015-11-08 00:32:30 -0600 |
commit | 8a1509d0a6e7aedc1c3f6f13f0d7b2e0d83d6e2d (patch) | |
tree | 73bbd087564757a459d1a507b6c92dae3ed6f674 /toys/pending | |
parent | f0ddca8f88152f25f5aefba7483c389e970c5155 (diff) | |
download | toybox-8a1509d0a6e7aedc1c3f6f13f0d7b2e0d83d6e2d.tar.gz |
Bugfix for route flags.
Diffstat (limited to 'toys/pending')
-rw-r--r-- | toys/pending/route.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/toys/pending/route.c b/toys/pending/route.c index 9ea8cc09..08de5bf3 100644 --- a/toys/pending/route.c +++ b/toys/pending/route.c @@ -14,9 +14,11 @@ config ROUTE Display/Edit kernel routing tables. - -n Don't resolve names - -e Display other/more information + -n no name lookups + -e display other/more information -A inet{6} Select Address Family + + reject mod dyn reinstate metric netmask gw mss window irtt dev */ #define FOR_route @@ -92,7 +94,7 @@ static void get_flag_value(char *str, int flags) int i = 0, mask = 0x105003f; for (; mask; mask>>=1) if (mask&1) { - if (1<<i) *str++ = "UGHRDMDAC"[i]; + if (flags&(1<<i)) *str++ = "UGHRDMDAC"[i]; i++; } *str = 0; |