Skip to content

Commit

Permalink
remove debugging messages
Browse files Browse the repository at this point in the history
  • Loading branch information
Yay295 committed Jul 8, 2024
1 parent 1962257 commit 3bd0c51
Showing 1 changed file with 0 additions and 34 deletions.
34 changes: 0 additions & 34 deletions src/_imaging.c
Original file line number Diff line number Diff line change
Expand Up @@ -3825,8 +3825,6 @@ _compare_pixels(
mask = 0xff0000ff;
}

PyErr_Format(PyExc_Exception, "mode mask : %s 0x%08x", mode, mask);

if (mask == 0xffffffff) {
// If we aren't masking anything we can use memcmp.
for (int y = 0; y < ysize; y++) {
Expand All @@ -3841,15 +3839,6 @@ _compare_pixels(
UINT32 *line_b = (UINT32 *)pixels_b[y];
for (int x = 0; x < xsize; x++, line_a++, line_b++) {
if ((*line_a & mask) != (*line_b & mask)) {
PyErr_Format(
PyExc_Exception,
"line %i index %i value a b mask : 0x%08x 0x%08x 0x%08x",
y,
x,
*line_a,
*line_b,
mask
);
return 1;
}
}
Expand All @@ -3876,14 +3865,6 @@ image_richcompare(const ImagingObject *self, const PyObject *other, const int op
const Imaging img_a = self->image;
const Imaging img_b = ((ImagingObject *)other)->image;

PyErr_Format(
PyExc_Exception,
"a mode, b mode, diff : %s %s %i",
img_a->mode,
img_b->mode,
strcmp(img_a->mode, img_a->mode)
);

if (
strcmp(img_a->mode, img_b->mode)
|| img_a->xsize != img_b->xsize
Expand All @@ -3899,14 +3880,6 @@ image_richcompare(const ImagingObject *self, const PyObject *other, const int op
const ImagingPalette palette_a = img_a->palette;
const ImagingPalette palette_b = img_b->palette;
if (palette_a || palette_b) {
PyErr_Format(
PyExc_Exception,
"pa mode, pb mode, diff : %s %s %i",
palette_a->mode,
palette_b->mode,
strcmp(palette_a->mode, palette_b->mode)
);

const UINT8 *palette_a_data = palette_a->palette;
const UINT8 *palette_b_data = palette_b->palette;
const UINT8 **palette_a_data_ptr = &palette_a_data;
Expand All @@ -3931,13 +3904,6 @@ image_richcompare(const ImagingObject *self, const PyObject *other, const int op
}
}

PyErr_Format(
PyExc_Exception,
"linesize a b : %i %i",
img_a->linesize,
img_b->linesize
);

if (_compare_pixels(
img_a->mode,
img_a->ysize,
Expand Down

0 comments on commit 3bd0c51

Please sign in to comment.