diff options
| author | Mickael Savinaud <savmickael@users.noreply.github.com> | 2011-07-28 10:45:22 +0000 |
|---|---|---|
| committer | Mickael Savinaud <savmickael@users.noreply.github.com> | 2011-07-28 10:45:22 +0000 |
| commit | e716a316f60f66cd5a6fb07b88b2cb8b9c815cec (patch) | |
| tree | 4f7e13104780fa5ac5199111cd64088ada0d9918 /applications/codec | |
| parent | c2b0a8101b21babd3e3572c18497df2c9a1f85ac (diff) | |
manage case 0 frames inside yuv_num_frames function and correct some warnings with gcc4.5 (credit to Winfried)
Diffstat (limited to 'applications/codec')
| -rw-r--r-- | applications/codec/convert.c | 3 | ||||
| -rw-r--r-- | applications/codec/j2k_to_image.c | 2 |
2 files changed, 2 insertions, 3 deletions
diff --git a/applications/codec/convert.c b/applications/codec/convert.c index 502539f7..c7adabe9 100644 --- a/applications/codec/convert.c +++ b/applications/codec/convert.c @@ -1968,7 +1968,6 @@ int imagetotif(opj_image_t * image, const char *outfile) int width, height, imgsize; int bps,index,adjust, sgnd; int ushift, dshift, has_alpha, force16; - unsigned int last_i=0; TIFF *tif; tdata_t buf; tstrip_t strip; @@ -2029,7 +2028,7 @@ int imagetotif(opj_image_t * image, const char *outfile) for(strip = 0; strip < TIFFNumberOfStrips(tif); strip++) { unsigned char *dat8; - tsize_t i, ssize; + tsize_t i, ssize, last_i = 0; int step, restx; ssize = TIFFStripSize(tif); dat8 = (unsigned char*)buf; diff --git a/applications/codec/j2k_to_image.c b/applications/codec/j2k_to_image.c index b8f237bd..3da83119 100644 --- a/applications/codec/j2k_to_image.c +++ b/applications/codec/j2k_to_image.c @@ -595,7 +595,7 @@ int main(int argc, char **argv) { file_length = ftell(fsrc); fseek(fsrc, 0, SEEK_SET); src = (unsigned char *) malloc(file_length); - if (fread(src, 1, file_length, fsrc) != file_length) + if (fread(src, 1, file_length, fsrc) != (size_t)file_length) { free(src); fclose(fsrc); |
