Skip to content
Browse files

CDVD: Add fallback path for blockdump source name unavailability

2 pass fallback cases for the untitled scenario was mentioned in the TODO comment to be completed, added  one of them. (Still doesn't seem reliable enough, but honestly when do we  Also modified blank space indentation at a part to tab space to satisfy lightning boi.
  • Loading branch information...
ssakash committed Jul 1, 2019
1 parent 7290576 commit a36d5a0221cccd6719fb6d17cd4954a998338dda
Showing with 8 additions and 6 deletions.
  1. +8 −6 pcsx2/CDVD/CDVDaccess.cpp
@@ -370,15 +370,17 @@ bool DoCDVDopen()
return true;

// TODO: "Untitled" should use pnach/slus name resolution, slus if no patch,
// and finally an "Untitled-[ElfCRC]" if no slus.

wxString somepick( Path::GetFilenameWithoutExt( m_SourceFilename[CurrentSourceType] ) );
if( somepick.IsEmpty() )
wxString somepick( Path::GetFilenameWithoutExt( m_SourceFilename[CurrentSourceType] ) );
//FWIW Disc serial availability doesn't seem reliable enough, sometimes it's there and sometime it's just null
//Shouldn't the serial be available all time? Potentially need to look into Elfreloadinfo() reliability
//TODO: Add extra fallback case for CRC.
if (somepick.IsEmpty() && !DiscSerial.IsEmpty())
somepick = L"Untitled-" + DiscSerial;
else if (somepick.IsEmpty())
somepick = L"Untitled";

if (g_Conf->CurrentBlockdump.IsEmpty())
g_Conf->CurrentBlockdump = wxGetCwd();
g_Conf->CurrentBlockdump = wxGetCwd();

wxString temp(Path::Combine(g_Conf->CurrentBlockdump, somepick));

1 comment on commit a36d5a0


This comment has been minimized.

Copy link
Member Author

commented on a36d5a0 Jul 1, 2019

Didn't complete the message in commit message (Still doesn't seem reliable enough, but honestly when do we hit the name unavailability part anyway)

Please sign in to comment.
You can’t perform that action at this time.