cdi, chd: better error messages

This commit is contained in:
Flyinghead 2018-10-22 17:39:02 +02:00
parent efcb95b4ee
commit 282534d7bc
2 changed files with 7 additions and 3 deletions

View File

@ -69,7 +69,10 @@ bool CHDDisc::TryOpen(const wchar* file)
chd_error err=chd_open(file,CHD_OPEN_READ,0,&chd);
if (err!=CHDERR_NONE)
{
printf("chd: chd_open failed for file %s: %d\n", file, err);
return false;
}
printf("chd: parsing file %s\n",file);
@ -164,4 +167,4 @@ Disc* chd_parse(const wchar* file)
delete rv;
return 0;
}
}
}

View File

@ -137,8 +137,9 @@ Disc* OpenDisc(const wchar* fn)
rv = drivers[i](fn);
if (rv && cdi_parse == drivers[i]) {
const wchar warn_str[] = "Warning: CDI Image Loaded!\n Many CDI images are known to be defective, GDI or CHD format is preferred. Please only file bug reports when using images known to be good (GDI or CHD).";
printf(warn_str);
const wchar warn_str[] = "Warning: CDI Image Loaded!\n Many CDI images are known to be defective, GDI or CHD format is preferred. "
"Please only file bug reports when using images known to be good (GDI or CHD).";
printf("%s\n", warn_str);
break;
}