cpuboard: support loading rom using full path

This commit is contained in:
Frode Solheim 2015-09-04 23:59:59 +02:00
parent bf34bd8f84
commit 6d618bdcd6

View File

@ -2035,6 +2035,10 @@ static struct zfile *board_rom_open(int *roms, const TCHAR *name)
if (rl)
zf = read_rom(rl->rd);
if (!zf && name) {
zf = zfile_fopen(name, _T("rb"), ZFD_NORMAL);
if (zf) {
return zf;
}
TCHAR path[MAX_DPATH];
fetch_rompath(path, sizeof path / sizeof(TCHAR));
_tcscat(path, name);