mirror of
https://github.com/yarrick/iodine.git
synced 2024-11-27 12:05:15 +00:00
hosthost
This commit is contained in:
parent
4a9887c9df
commit
a3735705c7
5
read.c
5
read.c
@ -31,6 +31,7 @@ readname(char *packet, char **src, char *dst, size_t length)
|
|||||||
p = *src;
|
p = *src;
|
||||||
while(*p && len < length) {
|
while(*p && len < length) {
|
||||||
c = *p++;
|
c = *p++;
|
||||||
|
len++;
|
||||||
|
|
||||||
/* is this a compressed label? */
|
/* is this a compressed label? */
|
||||||
if((c & 0xc0) == 0xc0) {
|
if((c & 0xc0) == 0xc0) {
|
||||||
@ -47,9 +48,9 @@ readname(char *packet, char **src, char *dst, size_t length)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (*p != 0)
|
if (*p != 0)
|
||||||
*dst = '.';
|
*dst++ = '.';
|
||||||
else
|
else
|
||||||
*dst = '\0';
|
*dst++ = '\0';
|
||||||
}
|
}
|
||||||
(*src) = p+1;
|
(*src) = p+1;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user