Skip to content
Permalink
Browse files

RedumpVerifier: Don't crash on missing hyphen in serial

  • Loading branch information...
JosJuice committed Oct 30, 2019
1 parent a52b875 commit 49977446dd859e3079698a4c79948a47644984e1
Showing with 1 addition and 1 deletion.
  1. +1 −1 Source/Core/DiscIO/VolumeVerifier.cpp
@@ -265,7 +265,7 @@ std::vector<RedumpVerifier::PotentialMatch> RedumpVerifier::ScanDatfile(const st
const size_t game_id_start =
first_dash == std::string::npos ? std::string::npos : first_dash + 1;

if (serial.size() < game_id_start + 4)
if (game_id_start == std::string::npos || serial.size() < game_id_start + 4)
{
ERROR_LOG(DISCIO, "Invalid serial in redump datfile: %s", serial_str.c_str());
continue;

0 comments on commit 4997744

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