Handle exceptions in int conversions (#2092)
* RageUtil: Add exception-safe wrappers around std::stoi, stol, stoll * Replace use of std::stoi with exception-safe StringToInt
This commit is contained in:
+1
-1
@@ -2523,7 +2523,7 @@ RString Profile::MakeUniqueFileNameNoExtension( RString sDir, RString sFileNameB
|
||||
continue;
|
||||
|
||||
ASSERT( matches.size() == 1 );
|
||||
iIndex = std::stoi( matches[0] )+1;
|
||||
iIndex = StringToInt( matches[0] )+1;
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user