diff options
author | Denys Vlasenko <vda.linux@googlemail.com> | 2011-11-16 20:17:12 +0100 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2011-11-16 20:17:12 +0100 |
commit | a092a89d8f052072e562861f2968573d89e10dd5 (patch) | |
tree | 43e7300d1825899e5c95ae9f557d0e2d1efde228 /networking/udhcp/dhcpc.c | |
parent | 39b233182c0a13200be051b993da181a1db80a87 (diff) | |
download | busybox-w32-a092a89d8f052072e562861f2968573d89e10dd5.tar.gz busybox-w32-a092a89d8f052072e562861f2968573d89e10dd5.tar.bz2 busybox-w32-a092a89d8f052072e562861f2968573d89e10dd5.zip |
udhcpc6: rudimentary code to export data to script; fix IAADDR parsing
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'networking/udhcp/dhcpc.c')
-rw-r--r-- | networking/udhcp/dhcpc.c | 18 |
1 files changed, 0 insertions, 18 deletions
diff --git a/networking/udhcp/dhcpc.c b/networking/udhcp/dhcpc.c index 3c4e8dee1..43d682341 100644 --- a/networking/udhcp/dhcpc.c +++ b/networking/udhcp/dhcpc.c | |||
@@ -123,24 +123,6 @@ static int sprint_nip(char *dest, const char *pre, const uint8_t *ip) | |||
123 | return sprintf(dest, "%s%u.%u.%u.%u", pre, ip[0], ip[1], ip[2], ip[3]); | 123 | return sprintf(dest, "%s%u.%u.%u.%u", pre, ip[0], ip[1], ip[2], ip[3]); |
124 | } | 124 | } |
125 | 125 | ||
126 | static int sprint_nip6(char *dest, /*const char *pre,*/ const uint8_t *ip) | ||
127 | { | ||
128 | char hexstrbuf[16 * 2]; | ||
129 | bin2hex(hexstrbuf, (void*)ip, 16); | ||
130 | return sprintf(dest, /* "%s" */ | ||
131 | "%.4s:%.4s:%.4s:%.4s:%.4s:%.4s:%.4s:%.4s", | ||
132 | /* pre, */ | ||
133 | hexstrbuf + 0 * 4, | ||
134 | hexstrbuf + 1 * 4, | ||
135 | hexstrbuf + 2 * 4, | ||
136 | hexstrbuf + 3 * 4, | ||
137 | hexstrbuf + 4 * 4, | ||
138 | hexstrbuf + 5 * 4, | ||
139 | hexstrbuf + 6 * 4, | ||
140 | hexstrbuf + 7 * 4 | ||
141 | ); | ||
142 | } | ||
143 | |||
144 | /* really simple implementation, just count the bits */ | 126 | /* really simple implementation, just count the bits */ |
145 | static int mton(uint32_t mask) | 127 | static int mton(uint32_t mask) |
146 | { | 128 | { |