From 174326d6c38c00cb3d6b5d17d1b342443570487a Mon Sep 17 00:00:00 2001 From: Relintai Date: Wed, 23 Mar 2022 15:51:34 +0100 Subject: [PATCH] Fix an another warning. --- core/io/http_client.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/core/io/http_client.cpp b/core/io/http_client.cpp index 753ef6ce8a..3031a2b06d 100644 --- a/core/io/http_client.cpp +++ b/core/io/http_client.cpp @@ -717,7 +717,7 @@ PoolByteArray HTTPClient::read_response_body_chunk() { ret.resize(chunk.size() - 2); PoolByteArray::Write w = ret.write(); - memcpy(w.ptr(), chunk.ptr(), chunk.size() - 2); + memcpy(w.ptr(), chunk.ptr(), ret.size()); chunk.clear(); }