diff --git a/src/jpeg2mem.c b/src/jpeg2mem.c index 05ba3cc..d92239e 100755 --- a/src/jpeg2mem.c +++ b/src/jpeg2mem.c @@ -67,6 +67,7 @@ MemImage_t * LoadJPEG(char* FileName, int scale_denom, int discard_colors, int P if (setjmp(jerr.setjmp_buffer)) { // If we get here, the JPEG code has signaled an error. // We need to clean up the JPEG object, close the input file, and return. + fprintf(Log, "Error reading jpeg \"%s\" at %ld\n", FileName, ftell(file)); jpeg_destroy_decompress(&info); fclose(file); return NULL; diff --git a/src/jpgfile.c b/src/jpgfile.c index 7cb6fd0..c7bcde5 100755 --- a/src/jpgfile.c +++ b/src/jpgfile.c @@ -107,7 +107,7 @@ static int FindExifInFile (FILE * infile) lh = fgetc(infile); ll = fgetc(infile); if (lh == EOF || ll == EOF){ - fprintf(Log, "Unexpected end of file"); + fprintf(Log, "Unexpected end of file at %ld",ftell(infile)); return 0; }