about summary refs log tree commit diff
path: root/lib
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2006-10-26 15:13:11 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2006-10-26 15:13:11 +0000
commit02dd49fe72ca941bf35b66b31019139dd8e4e377 (patch)
tree75bae67b624e7ad96c284afb4c7cd4b1f7935c3d /lib
parent111180e9ec6772eb480179f96dbb581118670922 (diff)
downloadnetpbm-mirror-02dd49fe72ca941bf35b66b31019139dd8e4e377.tar.gz
netpbm-mirror-02dd49fe72ca941bf35b66b31019139dd8e4e377.tar.xz
netpbm-mirror-02dd49fe72ca941bf35b66b31019139dd8e4e377.zip
Release 10.36.06
git-svn-id: http://svn.code.sf.net/p/netpbm/code/advanced@112 9d0c8265-081b-0410-96cb-a4ca84ce46f8
Diffstat (limited to 'lib')
-rw-r--r--lib/libpam.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libpam.c b/lib/libpam.c
index 6d2acba7..60d446d9 100644
--- a/lib/libpam.c
+++ b/lib/libpam.c
@@ -90,7 +90,7 @@ validateComputableSize(struct pam * const pamP) {
 
     if (depth > INT_MAX/sizeof(sample))
         pm_error("image depth (%u) too large to be processed", depth);
-    else if (depth * sizeof(sample) > INT_MAX/pamP->width)
+    else if (pamP->width > 0 && depth * sizeof(sample) > INT_MAX/pamP->width)
         pm_error("image width and depth (%u, %u) too large "
                  "to be processed.", pamP->width, depth);
     else if (pamP->width * (depth * sizeof(sample)) >