Commit 769224a8 authored by Mark Andrews's avatar Mark Andrews
Browse files

state fw_copy is never used; n only needs to be set for fw_ordinary;

(cherry picked from commit d956d9689c13b093fff5faf6b10f06338354dcfc)
parent e58154a6
......@@ -53,7 +53,6 @@ typedef enum {
typedef enum {
fw_start = 0,
fw_ordinary,
fw_copy,
fw_newcurrent
} fw_state;
......@@ -1899,7 +1898,6 @@ dns_name_fromwire(dns_name_t *name, isc_buffer_t *source,
0)
return (DNS_R_DISALLOWED);
new_current = c & 0x3F;
n = 1;
state = fw_newcurrent;
} else
return (DNS_R_BADLABELTYPE);
......@@ -1907,8 +1905,6 @@ dns_name_fromwire(dns_name_t *name, isc_buffer_t *source,
case fw_ordinary:
if (downcase)
c = maptolower[c];
/* FALLTHROUGH */
case fw_copy:
*ndata++ = c;
n--;
if (n == 0)
......@@ -1917,9 +1913,6 @@ dns_name_fromwire(dns_name_t *name, isc_buffer_t *source,
case fw_newcurrent:
new_current *= 256;
new_current += c;
n--;
if (n != 0)
break;
if (new_current >= biggest_pointer)
return (DNS_R_BADPOINTER);
biggest_pointer = new_current;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment