You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-05 12:10:55 +00:00
CI: Sync configuration with 4.4 branch
Includes cherry-picks of warning fixes from8d1462c748and template builds unit tests fixes from17929a3443and832695eb2c.
This commit is contained in:
@@ -662,15 +662,16 @@ PackedByteArray HTTPClientTCP::read_response_body_chunk() {
|
||||
chunk_left -= rec;
|
||||
|
||||
if (chunk_left == 0) {
|
||||
if (chunk[chunk.size() - 2] != '\r' || chunk[chunk.size() - 1] != '\n') {
|
||||
const int chunk_size = chunk.size();
|
||||
if (chunk[chunk_size - 2] != '\r' || chunk[chunk_size - 1] != '\n') {
|
||||
ERR_PRINT("HTTP Invalid chunk terminator (not \\r\\n)");
|
||||
status = STATUS_CONNECTION_ERROR;
|
||||
break;
|
||||
}
|
||||
|
||||
ret.resize(chunk.size() - 2);
|
||||
ret.resize(chunk_size - 2);
|
||||
uint8_t *w = ret.ptrw();
|
||||
memcpy(w, chunk.ptr(), chunk.size() - 2);
|
||||
memcpy(w, chunk.ptr(), chunk_size - 2);
|
||||
chunk.clear();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user