about summary refs log tree commit diff
diff options
context:
space:
mode:
authorgiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2023-10-10 17:59:39 +0000
committergiraffedata <giraffedata@9d0c8265-081b-0410-96cb-a4ca84ce46f8>2023-10-10 17:59:39 +0000
commit0861102cd5955111404467c4fff111208bc9f06d (patch)
tree0c72a9a8f581676812f77223ea22f04ce158545b
parent248b5e23077a5b681fb84247878732b66917f851 (diff)
downloadnetpbm-mirror-0861102cd5955111404467c4fff111208bc9f06d.tar.gz
netpbm-mirror-0861102cd5955111404467c4fff111208bc9f06d.tar.xz
netpbm-mirror-0861102cd5955111404467c4fff111208bc9f06d.zip
Add comments
git-svn-id: http://svn.code.sf.net/p/netpbm/code/trunk@4746 9d0c8265-081b-0410-96cb-a4ca84ce46f8
-rw-r--r--lib/libpgm1.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/lib/libpgm1.c b/lib/libpgm1.c
index 43458f8a..0656e1e0 100644
--- a/lib/libpgm1.c
+++ b/lib/libpgm1.c
@@ -125,6 +125,13 @@ pgm_validateComputableMaxval(gray const maxval) {
 
        Code also sometimes iterates through sample values and quits when the
        value is greater than the maxval.
+
+       Code often divides by the maxval, but we don't have to check for maxval
+       == 0 as a computability problem because that is not a valid maxval.
+
+       Note that in the PNM Plain formats, there is no upper limit for a
+       maxval, though the 'gray' type does constrain what has been passed to
+       us.
     */
 
     if (maxval > INT_MAX-1)