Skip to content

Commit 94bab09

Browse files
Update libpng from 1.6.38 to 1.6.39 (#2838)
1 parent a23a58d commit 94bab09

File tree

9 files changed

+24
-24
lines changed

9 files changed

+24
-24
lines changed

vendor/libpng/png.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
#include "pngpriv.h"
1515

1616
/* Generate a compiler error if there is an old png.h in the search path. */
17-
typedef png_libpng_version_1_6_38 Your_png_h_is_not_version_1_6_38;
17+
typedef png_libpng_version_1_6_39 Your_png_h_is_not_version_1_6_39;
1818

1919
#ifdef __GNUC__
2020
/* The version tests may need to be added to, but the problem warning has
@@ -815,7 +815,7 @@ png_get_copyright(png_const_structrp png_ptr)
815815
return PNG_STRING_COPYRIGHT
816816
#else
817817
return PNG_STRING_NEWLINE \
818-
"libpng version 1.6.38" PNG_STRING_NEWLINE \
818+
"libpng version 1.6.39" PNG_STRING_NEWLINE \
819819
"Copyright (c) 2018-2022 Cosmin Truta" PNG_STRING_NEWLINE \
820820
"Copyright (c) 1998-2002,2004,2006-2018 Glenn Randers-Pehrson" \
821821
PNG_STRING_NEWLINE \
@@ -2710,7 +2710,7 @@ png_check_IHDR(png_const_structrp png_ptr,
27102710

27112711
int /* PRIVATE */
27122712
png_check_fp_number(png_const_charp string, size_t size, int *statep,
2713-
png_size_tp whereami)
2713+
size_t *whereami)
27142714
{
27152715
int state = *statep;
27162716
size_t i = *whereami;

vendor/libpng/png.h

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
/* png.h - header file for PNG reference library
33
*
4-
* libpng version 1.6.38 - September 14, 2022
4+
* libpng version 1.6.39 - November 20, 2022
55
*
66
* Copyright (c) 2018-2022 Cosmin Truta
77
* Copyright (c) 1998-2002,2004,2006-2018 Glenn Randers-Pehrson
@@ -15,7 +15,7 @@
1515
* libpng versions 0.89, June 1996, through 0.96, May 1997: Andreas Dilger
1616
* libpng versions 0.97, January 1998, through 1.6.35, July 2018:
1717
* Glenn Randers-Pehrson
18-
* libpng versions 1.6.36, December 2018, through 1.6.38, September 2022:
18+
* libpng versions 1.6.36, December 2018, through 1.6.39, November 2022:
1919
* Cosmin Truta
2020
* See also "Contributing Authors", below.
2121
*/
@@ -239,7 +239,7 @@
239239
* ...
240240
* 1.5.30 15 10530 15.so.15.30[.0]
241241
* ...
242-
* 1.6.38 16 10638 16.so.16.38[.0]
242+
* 1.6.39 16 10639 16.so.16.39[.0]
243243
*
244244
* Henceforth the source version will match the shared-library major and
245245
* minor numbers; the shared-library major version number will be used for
@@ -278,16 +278,16 @@
278278
*/
279279

280280
/* Version information for png.h - this should match the version in png.c */
281-
#define PNG_LIBPNG_VER_STRING "1.6.38"
282-
#define PNG_HEADER_VERSION_STRING " libpng version 1.6.38 - September 14, 2022\n"
281+
#define PNG_LIBPNG_VER_STRING "1.6.39"
282+
#define PNG_HEADER_VERSION_STRING " libpng version 1.6.39 - November 20, 2022\n"
283283

284284
#define PNG_LIBPNG_VER_SONUM 16
285285
#define PNG_LIBPNG_VER_DLLNUM 16
286286

287287
/* These should match the first 3 components of PNG_LIBPNG_VER_STRING: */
288288
#define PNG_LIBPNG_VER_MAJOR 1
289289
#define PNG_LIBPNG_VER_MINOR 6
290-
#define PNG_LIBPNG_VER_RELEASE 38
290+
#define PNG_LIBPNG_VER_RELEASE 39
291291

292292
/* This should be zero for a public release, or non-zero for a
293293
* development version. [Deprecated]
@@ -318,7 +318,7 @@
318318
* From version 1.0.1 it is:
319319
* XXYYZZ, where XX=major, YY=minor, ZZ=release
320320
*/
321-
#define PNG_LIBPNG_VER 10638 /* 1.6.38 */
321+
#define PNG_LIBPNG_VER 10639 /* 1.6.39 */
322322

323323
/* Library configuration: these options cannot be changed after
324324
* the library has been built.
@@ -428,7 +428,7 @@ extern "C" {
428428
/* This triggers a compiler error in png.c, if png.c and png.h
429429
* do not agree upon the version number.
430430
*/
431-
typedef char* png_libpng_version_1_6_38;
431+
typedef char* png_libpng_version_1_6_39;
432432

433433
/* Basic control structions. Read libpng-manual.txt or libpng.3 for more info.
434434
*

vendor/libpng/pngconf.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
/* pngconf.h - machine-configurable file for libpng
33
*
4-
* libpng version 1.6.38
4+
* libpng version 1.6.39
55
*
66
* Copyright (c) 2018-2022 Cosmin Truta
77
* Copyright (c) 1998-2002,2004,2006-2016,2018 Glenn Randers-Pehrson

vendor/libpng/pngpriv.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1946,7 +1946,7 @@ PNG_INTERNAL_FUNCTION(void,png_ascii_from_fixed,(png_const_structrp png_ptr,
19461946
* the problem character.) This has not been tested within libpng.
19471947
*/
19481948
PNG_INTERNAL_FUNCTION(int,png_check_fp_number,(png_const_charp string,
1949-
size_t size, int *statep, png_size_tp whereami),PNG_EMPTY);
1949+
size_t size, int *statep, size_t *whereami),PNG_EMPTY);
19501950

19511951
/* This is the same but it checks a complete string and returns true
19521952
* only if it just contains a floating point number. As of 1.5.4 this

vendor/libpng/pngread.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3762,13 +3762,13 @@ png_image_read_direct(png_voidp argument)
37623762
mode = PNG_ALPHA_PNG;
37633763
output_gamma = PNG_DEFAULT_sRGB;
37643764
}
3765-
3765+
37663766
if ((change & PNG_FORMAT_FLAG_ASSOCIATED_ALPHA) != 0)
37673767
{
37683768
mode = PNG_ALPHA_OPTIMIZED;
37693769
change &= ~PNG_FORMAT_FLAG_ASSOCIATED_ALPHA;
37703770
}
3771-
3771+
37723772
/* If 'do_local_background' is set check for the presence of gamma
37733773
* correction; this is part of the work-round for the libpng bug
37743774
* described above.

vendor/libpng/pngrutil.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3186,7 +3186,7 @@ png_check_chunk_length(png_const_structrp png_ptr, png_uint_32 length)
31863186
{
31873187
png_debug2(0," length = %lu, limit = %lu",
31883188
(unsigned long)length,(unsigned long)limit);
3189-
png_chunk_error(png_ptr, "chunk data is too large");
3189+
png_benign_error(png_ptr, "chunk data is too large");
31903190
}
31913191
}
31923192

vendor/libpng/pngtest.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2155,4 +2155,4 @@ main(void)
21552155
#endif
21562156

21572157
/* Generate a compiler error if there is an old png.h in the search path. */
2158-
typedef png_libpng_version_1_6_38 Your_png_h_is_not_version_1_6_38;
2158+
typedef png_libpng_version_1_6_39 Your_png_h_is_not_version_1_6_39;

vendor/libpng/pngwrite.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -75,10 +75,10 @@ write_unknown_chunks(png_structrp png_ptr, png_const_inforp info_ptr,
7575
* library. If you have a new chunk to add, make a function to write it,
7676
* and put it in the correct location here. If you want the chunk written
7777
* after the image data, put it in png_write_end(). I strongly encourage
78-
* you to supply a PNG_INFO_ flag, and check info_ptr->valid before writing
79-
* the chunk, as that will keep the code from breaking if you want to just
80-
* write a plain PNG file. If you have long comments, I suggest writing
81-
* them in png_write_end(), and compressing them.
78+
* you to supply a PNG_INFO_<chunk> flag, and check info_ptr->valid before
79+
* writing the chunk, as that will keep the code from breaking if you want
80+
* to just write a plain PNG file. If you have long comments, I suggest
81+
* writing them in png_write_end(), and compressing them.
8282
*/
8383
void PNGAPI
8484
png_write_info_before_PLTE(png_structrp png_ptr, png_const_inforp info_ptr)

vendor/libpng/pngwutil.c

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
/* pngwutil.c - utilities to write a PNG file
33
*
4-
* Copyright (c) 2018 Cosmin Truta
4+
* Copyright (c) 2018-2022 Cosmin Truta
55
* Copyright (c) 1998-2002,2004,2006-2018 Glenn Randers-Pehrson
66
* Copyright (c) 1996-1997 Andreas Dilger
77
* Copyright (c) 1995-1996 Guy Eric Schalnat, Group 42, Inc.
@@ -1747,7 +1747,7 @@ png_write_pCAL(png_structrp png_ptr, png_charp purpose, png_int_32 X0,
17471747
{
17481748
png_uint_32 purpose_len;
17491749
size_t units_len, total_len;
1750-
png_size_tp params_len;
1750+
size_t *params_len;
17511751
png_byte buf[10];
17521752
png_byte new_purpose[80];
17531753
int i;
@@ -1769,7 +1769,7 @@ png_write_pCAL(png_structrp png_ptr, png_charp purpose, png_int_32 X0,
17691769
png_debug1(3, "pCAL units length = %d", (int)units_len);
17701770
total_len = purpose_len + units_len + 10;
17711771

1772-
params_len = (png_size_tp)png_malloc(png_ptr,
1772+
params_len = (size_t *)png_malloc(png_ptr,
17731773
(png_alloc_size_t)((png_alloc_size_t)nparams * (sizeof (size_t))));
17741774

17751775
/* Find the length of each parameter, making sure we don't count the

0 commit comments

Comments
 (0)