From 124628012fd83f2bb7574a455ac49a2d40f4c43c Mon Sep 17 00:00:00 2001 From: Stephen White Date: Mon, 1 Jul 2019 21:16:08 +1000 Subject: [PATCH] VICE flip lists (ie.VFL files) work like .LST files. --- src/DiskImage.cpp | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/DiskImage.cpp b/src/DiskImage.cpp index 171075f..10cbc63 100644 --- a/src/DiskImage.cpp +++ b/src/DiskImage.cpp @@ -1161,7 +1161,7 @@ DiskImage::DiskType DiskImage::GetDiskImageTypeViaExtention(const char* diskImag return NBZ; else if (toupper((char)ext[1]) == 'D' && ext[2] == '6' && ext[3] == '4') return D64; - else if (toupper((char)ext[1]) == 'L' && toupper((char)ext[2]) == 'S' && toupper((char)ext[3]) == 'T') + else if (IsLSTExtention(diskImageName)) return LST; else if (toupper((char)ext[1]) == 'D' && ext[2] == '8' && ext[3] == '1') return D81; @@ -1202,7 +1202,14 @@ bool DiskImage::IsLSTExtention(const char* diskImageName) { char* ext = strrchr((char*)diskImageName, '.'); - if (ext && toupper((char)ext[1]) == 'L' && toupper((char)ext[2]) == 'S' && toupper((char)ext[3]) == 'T') + if (ext && + ( + (toupper((char)ext[1]) == 'L' && toupper((char)ext[2]) == 'S' && toupper((char)ext[3]) == 'T') + || + (toupper((char)ext[1]) == 'V' && toupper((char)ext[2]) == 'F' && toupper((char)ext[3]) == 'L') + ) + ) + return true; return false; }