use content_size == new_size

This commit is contained in:
lyon1998 2022-03-15 17:10:05 +08:00
parent 8b9b124bd5
commit 2292d3ab97

View File

@ -103,7 +103,7 @@ uint8_t* content_setContent(uint8_t* self, uint8_t* content, uint16_t size) {
}
/* only copy */
if (content_getSize(self) >= size) {
if (content_getSize(self) == size) {
__platform_memcpy(((__arg*)self)->content, content, size);
return self;
}