From b810da2788d0aca491bee55b0f9d97b48e682bbf Mon Sep 17 00:00:00 2001 From: Lei Zhang Date: Fri, 3 Nov 2017 22:18:18 +0000 Subject: Remove flags param from FXMEM_DefaultAlloc() and friends. Change-Id: I24404be0065156a1cfdec31bafdf72c27fa70142 Reviewed-on: https://pdfium-review.googlesource.com/17792 Reviewed-by: Chris Palmer Commit-Queue: Lei Zhang --- third_party/libpng16/0000-build-config.patch | 8 ++++---- third_party/libpng16/pngmem.c | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) (limited to 'third_party/libpng16') diff --git a/third_party/libpng16/0000-build-config.patch b/third_party/libpng16/0000-build-config.patch index 5c30866405..325b58fe02 100644 --- a/third_party/libpng16/0000-build-config.patch +++ b/third_party/libpng16/0000-build-config.patch @@ -5,8 +5,8 @@ diff a/third_party/libpng16/pngmem.c b/third_party/libpng16/pngmem.c #include "pngpriv.h" -+void* FXMEM_DefaultAlloc(int byte_size, int); -+void FXMEM_DefaultFree(void* pointer, int); ++void* FXMEM_DefaultAlloc(size_t byte_size); ++void FXMEM_DefaultFree(void* pointer); + #if defined(PNG_READ_SUPPORTED) || defined(PNG_WRITE_SUPPORTED) /* Free a png_struct */ @@ -16,7 +16,7 @@ diff a/third_party/libpng16/pngmem.c b/third_party/libpng16/pngmem.c else #endif - return malloc((size_t)size); /* checked for truncation above */ -+ return FXMEM_DefaultAlloc((int)size, 0); ++ return FXMEM_DefaultAlloc(size); } else @@ -25,7 +25,7 @@ diff a/third_party/libpng16/pngmem.c b/third_party/libpng16/pngmem.c #endif /* USER_MEM */ - free(ptr); -+ FXMEM_DefaultFree(ptr, 0); ++ FXMEM_DefaultFree(ptr); } #ifdef PNG_USER_MEM_SUPPORTED diff --git a/third_party/libpng16/pngmem.c b/third_party/libpng16/pngmem.c index b5507134fb..cf815a6f88 100644 --- a/third_party/libpng16/pngmem.c +++ b/third_party/libpng16/pngmem.c @@ -19,8 +19,8 @@ #include "pngpriv.h" -void* FXMEM_DefaultAlloc(int byte_size, int); -void FXMEM_DefaultFree(void* pointer, int); +void* FXMEM_DefaultAlloc(size_t byte_size); +void FXMEM_DefaultFree(void* pointer); #if defined(PNG_READ_SUPPORTED) || defined(PNG_WRITE_SUPPORTED) /* Free a png_struct */ @@ -95,7 +95,7 @@ png_malloc_base,(png_const_structrp png_ptr, png_alloc_size_t size), else #endif - return FXMEM_DefaultAlloc((int)size, 0); + return FXMEM_DefaultAlloc(size); } else @@ -252,7 +252,7 @@ png_free_default,(png_const_structrp png_ptr, png_voidp ptr),PNG_DEPRECATED) return; #endif /* USER_MEM */ - FXMEM_DefaultFree(ptr, 0); + FXMEM_DefaultFree(ptr); } #ifdef PNG_USER_MEM_SUPPORTED -- cgit v1.2.3