diff options
-rw-r--r-- | converter/pbm/pbmtogo.c | 6 | ||||
-rw-r--r-- | doc/HISTORY | 10 |
2 files changed, 11 insertions, 5 deletions
diff --git a/converter/pbm/pbmtogo.c b/converter/pbm/pbmtogo.c index b4f3f372..23b2ee9a 100644 --- a/converter/pbm/pbmtogo.c +++ b/converter/pbm/pbmtogo.c @@ -164,7 +164,7 @@ main(int argc, padright = rucols - cols; for (i = 0; i < GRAPHON_WIDTH_BYTES; ++i ) - buffer[i] = 0; + buffer[i] = oldscanline[i] = 0; putinit(); /* Start donwloading screen raster */ @@ -215,7 +215,7 @@ main(int argc, { olditem = buffer[nbyte++]; ucount++; - } while ((olditem != buffer[nbyte]) + } while (nbyte < bytesperrow && (olditem != buffer[nbyte]) && (ucount < MIN(bytesperrow, MAX_REPEAT))); if ((ucount != MAX_REPEAT) && (nbyte != bytesperrow)) { @@ -246,7 +246,7 @@ main(int argc, { olditem = buffer[nbyte++]; ecount++; - } while ((olditem == buffer[nbyte]) + } while (nbyte < bytesperrow && (olditem == buffer[nbyte]) && (ecount < MIN(bytesperrow, MAX_REPEAT))); if (ecount > 1) { diff --git a/doc/HISTORY b/doc/HISTORY index ca8743da..15289c7a 100644 --- a/doc/HISTORY +++ b/doc/HISTORY @@ -9,8 +9,14 @@ not yet BJH Release 10.71.00 sbigtopgm: fix detection of camera type. Always broken (sbigtopgm was new in Netpbm 8.3 (March 2000)). - sbigtopgm: fix recognition of compressed image. Always broken - (sbigtopgm was new in Netpbm 8.3 (March 2000)). + sbigtopgm: fix recognition of compressed image. Broken in + Netpbm 10.70 (March 2015). + + pbmtogo: Fix bug: garbage first row. Broken at least since + November 1989. + + pbmtogo: Fix bug: buffer overrun with certain input. Broken + at least since November 1989. libnetpbm: pm_stripeq: fix bug: wild pointer access when comparator is shorter than comparand. Doesn't affect function, |