mirror of
https://github.com/holub/mame
synced 2025-05-29 17:13:05 +03:00
Fix softload of cassettes (no whatsnew)
This commit is contained in:
parent
dfbcf3106b
commit
3f1e25efc4
@ -270,7 +270,17 @@ bool cassette_image_device::call_load()
|
||||
{
|
||||
is_writable = !is_readonly();
|
||||
cassette_flags = is_writable ? (CASSETTE_FLAG_READWRITE|CASSETTE_FLAG_SAVEONEXIT) : CASSETTE_FLAG_READONLY;
|
||||
extension = filetype();
|
||||
if (software_entry()==NULL) {
|
||||
extension = filetype();
|
||||
} else {
|
||||
astring fname = astring(m_mame_file->filename());
|
||||
int loc = fname.rchr(0,'.');
|
||||
if (loc!=-1) {
|
||||
extension = fname.substr(loc + 1,fname.len()-loc).cstr();
|
||||
} else {
|
||||
extension = "";
|
||||
}
|
||||
}
|
||||
err = cassette_open_choices((void *)image, &image_ioprocs, extension, m_formats, cassette_flags, &m_cassette);
|
||||
|
||||
/* this is kind of a hack */
|
||||
|
Loading…
Reference in New Issue
Block a user