1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
|
--- libpng-1.2.5.orig/pngconf.h 2002-10-03 13:32:27.000000000 +0200
+++ libpng-1.2.5/pngconf.h 2004-04-28 13:40:03.617656368 +0200
@@ -252,8 +252,8 @@
# undef _BSD_SOURCE
# endif
# ifdef _SETJMP_H
- __png.h__ already includes setjmp.h;
- __dont__ include it again.;
+#warning __png.h__ already includes setjmp.h;
+#warning __dont__ include it again.;
# endif
# endif /* __linux__ */
--- libpng3-1.2.5.orig/pngrtran.c
+++ libpng3-1.2.5/pngrtran.c
@@ -1930,7 +1930,7 @@
if (flags & PNG_FLAG_FILLER_AFTER)
{
png_bytep sp = row + (png_size_t)row_width * 3;
- png_bytep dp = sp + (png_size_t)row_width;
+ png_bytep dp = sp + (png_size_t)row_width ;
for (i = 1; i < row_width; i++)
{
*(--dp) = lo_filler;
@@ -1947,7 +1947,7 @@
else
{
png_bytep sp = row + (png_size_t)row_width * 3;
- png_bytep dp = sp + (png_size_t)row_width;
+ png_bytep dp = sp + (png_size_t)row_width ;
for (i = 0; i < row_width; i++)
{
*(--dp) = *(--sp);
@@ -1965,8 +1965,8 @@
/* This changes the data from RRGGBB to RRGGBBXX */
if (flags & PNG_FLAG_FILLER_AFTER)
{
- png_bytep sp = row + (png_size_t)row_width * 3;
- png_bytep dp = sp + (png_size_t)row_width;
+ png_bytep sp = row + (png_size_t)row_width * 6;
+ png_bytep dp = sp + (png_size_t)row_width * 2;
for (i = 1; i < row_width; i++)
{
*(--dp) = hi_filler;
@@ -1987,8 +1987,8 @@
/* This changes the data from RRGGBB to XXRRGGBB */
else
{
- png_bytep sp = row + (png_size_t)row_width * 3;
- png_bytep dp = sp + (png_size_t)row_width;
+ png_bytep sp = row + (png_size_t)row_width * 6;
+ png_bytep dp = sp + (png_size_t)row_width * 2;
for (i = 0; i < row_width; i++)
{
*(--dp) = *(--sp);
--- libpng3-1.2.5.orig/pngerror.c 2002-10-03 05:32:27.000000000 -0600
+++ libpng3-1.2.5/pngerror.c 2004-04-29 09:26:18.000000000 -0600
@@ -135,10 +135,12 @@
buffer[iout] = 0;
else
{
+ png_size_t len = strnlen(error_message, 63);
+
buffer[iout++] = ':';
buffer[iout++] = ' ';
- png_memcpy(buffer+iout, error_message, 64);
- buffer[iout+63] = 0;
+ png_memcpy(buffer+iout, error_message, len);
+ buffer[iout+len] = 0;
}
}
|