mirror of
https://github.com/TelegramMessenger/Telegram-iOS.git
synced 2026-07-06 03:33:41 +02:00
Merge b73021a720 into 6e370e06d1
This commit is contained in:
commit
a170b56dfe
1 changed files with 1 additions and 1 deletions
|
|
@ -783,7 +783,6 @@ name_parse(u8 *packet, int length, int *idx, char *name_out, int name_out_len) {
|
|||
|
||||
for(;;) {
|
||||
u8 label_len;
|
||||
if (j >= length) return -1;
|
||||
GET8(label_len);
|
||||
if (!label_len) break;
|
||||
if (label_len & 0xc0) {
|
||||
|
|
@ -804,6 +803,7 @@ name_parse(u8 *packet, int length, int *idx, char *name_out, int name_out_len) {
|
|||
*cp++ = '.';
|
||||
}
|
||||
if (cp + label_len >= end) return -1;
|
||||
if (j + label_len > length) return -1;
|
||||
memcpy(cp, packet + j, label_len);
|
||||
cp += label_len;
|
||||
j += label_len;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue