summary refs log tree commit diff
path: root/bin/pngo.c
diff options
context:
space:
mode:
authorJune McEnroe <programble@gmail.com>2018-02-16 17:14:56 -0500
committerJune McEnroe <programble@gmail.com>2018-02-16 17:14:56 -0500
commitfba3c0ad8e2d766d829be1b2cf4d09d74d80a279 (patch)
treedf5dffd2429ddfdf2de9845971822e1d3f8abc53 /bin/pngo.c
parentHandle more color types, depths, IDATs in pngo (diff)
downloadsrc-fba3c0ad8e2d766d829be1b2cf4d09d74d80a279.tar.gz
src-fba3c0ad8e2d766d829be1b2cf4d09d74d80a279.zip
Fix paethPredictor comparison
Diffstat (limited to 'bin/pngo.c')
-rw-r--r--bin/pngo.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/bin/pngo.c b/bin/pngo.c
index 17ffbd62..b4563839 100644
--- a/bin/pngo.c
+++ b/bin/pngo.c
@@ -226,7 +226,7 @@ static uint8_t paethPredictor(uint8_t a, uint8_t b, uint8_t c) {
     int32_t pb = labs(p - (int32_t)b);
     int32_t pc = labs(p - (int32_t)c);
     if (pa <= pb && pa <= pc) return a;
-    if (pb < pc) return b;
+    if (pb <= pc) return b;
     return c;
 }