diff options
author | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2013-06-02 03:36:32 +0000 |
---|---|---|
committer | giraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8> | 2013-06-02 03:36:32 +0000 |
commit | 0389d7247b8c0e5b587566d6231d53be3e948e7a (patch) | |
tree | 0f0ed9b74d9dc671942128d3b11df27fcabcb414 /converter/ppm/411toppm.c | |
parent | fd4df4062a13889503c81c002576159ea6316234 (diff) | |
download | netpbm-mirror-0389d7247b8c0e5b587566d6231d53be3e948e7a.tar.gz netpbm-mirror-0389d7247b8c0e5b587566d6231d53be3e948e7a.tar.xz netpbm-mirror-0389d7247b8c0e5b587566d6231d53be3e948e7a.zip |
check for inconsistencies between specified width and height and size of input
git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@1922 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'converter/ppm/411toppm.c')
-rw-r--r-- | converter/ppm/411toppm.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/converter/ppm/411toppm.c b/converter/ppm/411toppm.c index b5e3c03b..c87d05a9 100644 --- a/converter/ppm/411toppm.c +++ b/converter/ppm/411toppm.c @@ -215,6 +215,9 @@ main(int argc, const char **argv) { ppm_writeppmrow(stdout, pixrow, cmdline.width, 255, 0); } + if (fgetc(ifP) != EOF) + pm_message("Extraneous data at end of image."); + pm_close(ifP); ppm_freerow(pixrow); |