diff options
author | Arthur Gautier <baloo@gandi.net> | 2015-07-28 05:35:00 +0000 |
---|---|---|
committer | Denys Vlasenko <vda.linux@googlemail.com> | 2015-07-30 03:03:58 +0200 |
commit | c29021e2a594fb29471c8c7e61ab8f45296622ba (patch) | |
tree | 4a10b401305812737521eb6b493b166342042316 /networking/udhcp/dhcpc.c | |
parent | 193ba408a4fd3313b1dc2eb5eb25885cfa4363f6 (diff) | |
download | busybox-w32-c29021e2a594fb29471c8c7e61ab8f45296622ba.tar.gz busybox-w32-c29021e2a594fb29471c8c7e61ab8f45296622ba.tar.bz2 busybox-w32-c29021e2a594fb29471c8c7e61ab8f45296622ba.zip |
udhcpc: dns labels can actually start with a number
While RFC1035 recommends a label not to start with a number, there is
actually no such limitation in dns. One may buy a domain name like
0x1.net and use it.
This commit remove this check and allow a user to use such domains.
Signed-off-by: Arthur Gautier <baloo@gandi.net>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'networking/udhcp/dhcpc.c')
-rw-r--r-- | networking/udhcp/dhcpc.c | 4 |
1 files changed, 0 insertions, 4 deletions
diff --git a/networking/udhcp/dhcpc.c b/networking/udhcp/dhcpc.c index 9d3d1a31c..811a1a1ee 100644 --- a/networking/udhcp/dhcpc.c +++ b/networking/udhcp/dhcpc.c | |||
@@ -156,10 +156,6 @@ static const char *valid_domain_label(const char *label) | |||
156 | for (;;) { | 156 | for (;;) { |
157 | ch = *label; | 157 | ch = *label; |
158 | if ((ch|0x20) < 'a' || (ch|0x20) > 'z') { | 158 | if ((ch|0x20) < 'a' || (ch|0x20) > 'z') { |
159 | if (pos == 0) { | ||
160 | /* label must begin with letter */ | ||
161 | return NULL; | ||
162 | } | ||
163 | if (ch < '0' || ch > '9') { | 159 | if (ch < '0' || ch > '9') { |
164 | if (ch == '\0' || ch == '.') | 160 | if (ch == '\0' || ch == '.') |
165 | return label; | 161 | return label; |