mirror of https://github.com/M66B/NetGuard.git
Revert "Revert "Fixed queuing of extended segments""
This reverts commit 78b0559257
.
This commit is contained in:
parent
78b0559257
commit
3eb30ea700
|
@ -1002,11 +1002,16 @@ void queue_tcp(const struct arguments *args,
|
||||||
s->len = datalen;
|
s->len = datalen;
|
||||||
s->data = malloc(datalen);
|
s->data = malloc(datalen);
|
||||||
memcpy(s->data, data, datalen);
|
memcpy(s->data, data, datalen);
|
||||||
} else
|
} else {
|
||||||
log_android(ANDROID_LOG_ERROR, "%s segment larger %u..%u < %u",
|
log_android(ANDROID_LOG_ERROR, "%s segment larger %u..%u < %u",
|
||||||
session,
|
session,
|
||||||
s->seq - cur->remote_start, s->seq + s->len - cur->remote_start,
|
s->seq - cur->remote_start, s->seq + s->len - cur->remote_start,
|
||||||
s->seq + datalen - cur->remote_start);
|
s->seq + datalen - cur->remote_start);
|
||||||
|
free(s->data);
|
||||||
|
s->len = datalen;
|
||||||
|
s->data = malloc(datalen);
|
||||||
|
memcpy(s->data, data, datalen);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue