mirror of
https://git.code.sf.net/p/libpng/code.git
synced 2025-07-10 18:04:09 +02:00
[master] Make png_set|get_compression_buffer_size() available even
when PNG_WRITE_SUPPORTED is not enabled. There was no good reason for this restriction, and PNG readers can gain a speed benefit in reading large iCCP chunks by increasing png_ptr->zbuf_size via these functions.
This commit is contained in:
2
pngset.c
2
pngset.c
@@ -1093,7 +1093,6 @@ png_set_rows(png_structp png_ptr, png_infop info_ptr, png_bytepp row_pointers)
|
||||
}
|
||||
#endif
|
||||
|
||||
#ifdef PNG_WRITE_SUPPORTED
|
||||
void PNGAPI
|
||||
png_set_compression_buffer_size(png_structp png_ptr,
|
||||
png_size_t size)
|
||||
@@ -1106,7 +1105,6 @@ png_set_compression_buffer_size(png_structp png_ptr,
|
||||
png_ptr->zstream.next_out = png_ptr->zbuf;
|
||||
png_ptr->zstream.avail_out = (uInt)png_ptr->zbuf_size;
|
||||
}
|
||||
#endif
|
||||
|
||||
void PNGAPI
|
||||
png_set_invalid(png_structp png_ptr, png_infop info_ptr, int mask)
|
||||
|
||||
Reference in New Issue
Block a user