[trunk] Add more test in j2k_random_tile_access

Update issue 186
This commit is contained in:
Mathieu Malaterre 2012-11-08 16:41:01 +00:00
parent fb0a11636f
commit 8f58b776b0
1 changed files with 6 additions and 1 deletions

View File

@ -104,7 +104,7 @@ static int infile_format(const char *fname)
const char *s, *magic_s;
int ext_format, magic_format;
unsigned char buf[12];
unsigned int l_nb_read;
OPJ_SIZE_T l_nb_read;
reader = fopen(fname, "rb");
@ -157,6 +157,7 @@ int main(int argc, char **argv)
{
FILE *fsrc = NULL;
OPJ_UINT32 index;
opj_dparameters_t parameters; /* decompression parameters */
opj_image_t* image = NULL;
opj_stream_t *l_stream = NULL; /* Stream */
@ -269,6 +270,10 @@ int main(int argc, char **argv)
fclose(fsrc); \
return EXIT_FAILURE; \
} \
for(index = 0; index < image->numcomps; ++index) { \
if( image->comps[index].data == NULL ) \
return EXIT_FAILURE; \
} \
fprintf(stdout, "Tile %d is decoded successfully\n", tile_index);
TEST_TILE(tile_ul)