Commit 0ab195d9 authored by Ladislav Láska's avatar Ladislav Láska

Zabraneno porovnani signed/unsigned (patch by MJ).

parent edd89453
......@@ -32,7 +32,7 @@ image_load(char *filename)
pbm_readpbminit(f, &cols, &rows, &fmt);
struct image *img = image_init(cols, rows);
for (int i = 0; i < img->rows; i++)
for (unsigned int i = 0; i < img->rows; i++)
pbm_readpbmrow_packed(f, img->bitmap + i * image_rowbytes(img),
img->cols, fmt);
......@@ -47,7 +47,7 @@ image_save(char *filename, struct image *img)
if (!f) { perror("save"); exit(EXIT_FAILURE); }
pbm_writepbminit(f, img->cols, img->rows, 0);
for (int i = 0; i < img->rows; i++)
for (unsigned int i = 0; i < img->rows; i++)
pbm_writepbmrow_packed(f, img->bitmap + i * image_rowbytes(img),
img->cols, 0);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment