Expose WebPMalloc() in addition to WebPFree()

and use it at various places, including for WebPData.

This is an API change!

Change-Id: Ic041323a1179c465292a4f981a86c4c34635d243
This commit is contained in:
Skal
2019-10-15 23:16:51 +02:00
parent af650c0bd2
commit a4df4aae73
12 changed files with 59 additions and 43 deletions

View File

@ -216,9 +216,14 @@ void WebPSafeFree(void* const ptr) {
free(ptr);
}
// Public API function.
// Public API functions.
void* WebPMalloc(size_t size) {
return WebPSafeMalloc(1, size);
}
void WebPFree(void* ptr) {
free(ptr);
WebPSafeFree(ptr);
}
//------------------------------------------------------------------------------