mirror of
https://github.com/webmproject/libwebp.git
synced 2025-04-04 16:06:49 +02:00
WebPMemoryWriterClear: use WebPMemoryWriterInit
Removes some common code between the two functions. Change-Id: If9f42e580e34dad63f3806750d9d7571941026b5
This commit is contained in:
parent
a4183d94c7
commit
e0ae21d231
@ -226,9 +226,7 @@ int WebPMemoryWrite(const uint8_t* data, size_t data_size,
|
||||
void WebPMemoryWriterClear(WebPMemoryWriter* writer) {
|
||||
if (writer != NULL) {
|
||||
WebPSafeFree(writer->mem);
|
||||
writer->mem = NULL;
|
||||
writer->size = 0;
|
||||
writer->max_size = 0;
|
||||
WebPMemoryWriterInit(writer);
|
||||
}
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user