diff options
author | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2007-02-21 21:37:28 +0000 |
---|---|---|
committer | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2007-02-21 21:37:28 +0000 |
commit | f2ff7fc0202fad727ec2fea4bc628205130dd86d (patch) | |
tree | d15069ec9dc556238e53f96be66989144b8beaca /converter/ppm/ppmtogif.c | |
parent | ab5f21f1db9de389b71d3326e5f7bb39ddaab34a (diff) | |
download | netpbm-mirror-f2ff7fc0202fad727ec2fea4bc628205130dd86d.tar.gz netpbm-mirror-f2ff7fc0202fad727ec2fea4bc628205130dd86d.tar.xz netpbm-mirror-f2ff7fc0202fad727ec2fea4bc628205130dd86d.zip |
Release 10.35.23
git-svn-id: http://svn.code.sf.net/p/netpbm/code/stable@231 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'converter/ppm/ppmtogif.c')
-rw-r--r-- | converter/ppm/ppmtogif.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/converter/ppm/ppmtogif.c b/converter/ppm/ppmtogif.c index 3100fea1..21ac1989 100644 --- a/converter/ppm/ppmtogif.c +++ b/converter/ppm/ppmtogif.c @@ -1203,6 +1203,14 @@ gifEncode(FILE * const ofP, unsigned int const initCodeSize = bitsPerPixel <= 1 ? 2 : bitsPerPixel; /* The initial code size */ + if (gWidth > 65535) + pm_error("Image width %u too large for GIF format. (Max 65535)", + gWidth); + + if (gHeight > 65535) + pm_error("Image height %u too large for GIF format. (Max 65535)", + gHeight); + writeGifHeader(ofP, gWidth, gHeight, gInterlace, background, bitsPerPixel, cmapP, comment); |