Skip to content

Commit

Permalink
Fix error affecting comparison with g_channel_tolerance
Browse files Browse the repository at this point in the history
  • Loading branch information
alxckn authored and vslavik committed Jan 17, 2020
1 parent 3be1b69 commit 4cba27c
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions diff-pdf.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -195,9 +195,9 @@ cairo_surface_t *diff_images(cairo_surface_t *s1, cairo_surface_t *s2,
unsigned char cb2 = *(data2 + x + 2);


if ( cr1 > (cr2+g_channel_tolerance) || cr2 < (cr2-g_channel_tolerance)
|| cg1 > (cg2+g_channel_tolerance) || cg2 < (cg2-g_channel_tolerance)
|| cb1 > (cb2+g_channel_tolerance) || cb2 < (cb2-g_channel_tolerance)
if ( cr1 > (cr2+g_channel_tolerance) || cr1 < (cr2-g_channel_tolerance)
|| cg1 > (cg2+g_channel_tolerance) || cg1 < (cg2-g_channel_tolerance)
|| cb1 > (cb2+g_channel_tolerance) || cb1 < (cb2-g_channel_tolerance)
)
{
changes = true;
Expand Down

0 comments on commit 4cba27c

Please sign in to comment.