"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/gd_gd2.c" between
libgd-2.2.4.tar.gz and libgd-2.2.5.tar.gz

About: LibGD is a library for the dynamic creation of images by programmers (PNG, JPEG, GIF, WebP, XPM, BMP support).

gd_gd2.c  (libgd-2.2.4):gd_gd2.c  (libgd-2.2.5)
skipping to change at line 77 skipping to change at line 77
* *
* Depending on format, the chunk may be ZLIB compressed. * Depending on format, the chunk may be ZLIB compressed.
*/ */
#ifdef HAVE_CONFIG_H #ifdef HAVE_CONFIG_H
#include "config.h" #include "config.h"
#endif #endif
/* 2.0.29: no more errno.h, makes windows happy */ /* 2.0.29: no more errno.h, makes windows happy */
#include <math.h> #include <math.h>
#include <limits.h>
#include <string.h> #include <string.h>
#include "gd.h" #include "gd.h"
#include "gd_errors.h" #include "gd_errors.h"
#include "gdhelpers.h" #include "gdhelpers.h"
/* 2.03: gd2 is no longer mandatory */ /* 2.03: gd2 is no longer mandatory */
/* JCE - test after including gd.h so that HAVE_LIBZ can be set in /* JCE - test after including gd.h so that HAVE_LIBZ can be set in
* a config.h file included by gd.h */ * a config.h file included by gd.h */
#ifdef HAVE_LIBZ #ifdef HAVE_LIBZ
#include <zlib.h> #include <zlib.h>
skipping to change at line 508 skipping to change at line 509
if (xhi > im->sx) { if (xhi > im->sx) {
xhi = im->sx; xhi = im->sx;
}; };
/*GD2_DBG(printf("y=%d: ",y)); */ /*GD2_DBG(printf("y=%d: ",y)); */
if (!gd2_compressed (fmt)) { if (!gd2_compressed (fmt)) {
for (x = xlo; x < xhi; x++) { for (x = xlo; x < xhi; x++) {
if (im->trueColor) { if (im->trueColor) {
if (!gdGetInt (&im->tpixe ls[y][x], in)) { if (!gdGetInt (&im->tpixe ls[y][x], in)) {
gd_error("gd2: EO F while reading\n"); gd_error("gd2: EO F while reading\n");
gdImageDestroy(im goto fail;
);
return NULL;
} }
} else { } else {
int ch; int ch;
if (!gdGetByte (&ch, in)) { if (!gdGetByte (&ch, in)) {
gd_error("gd2: EO F while reading\n"); gd_error("gd2: EO F while reading\n");
gdImageDestroy(im goto fail;
);
return NULL;
} }
im->pixels[y][x] = ch; im->pixels[y][x] = ch;
} }
} }
} else { } else {
for (x = xlo; x < xhi; x++) { for (x = xlo; x < xhi; x++) {
if (im->trueColor) { if (im->trueColor) {
/* 2.0.1: work around a g cc bug by being verbose. /* 2.0.1: work around a g cc bug by being verbose.
TBB */ TBB */
int a = chunkBuf[chunkPos ++] << 24; int a = chunkBuf[chunkPos ++] << 24;
 End of changes. 3 change blocks. 
6 lines changed or deleted 3 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)