-
Notifications
You must be signed in to change notification settings - Fork 279
Closed
Milestone
Description
Setting save_replay = C:\some_path\a.rep in bwapi.ini doesn't work as expected, the replay ends up in <starcraft>\C\some_path\a.rep. This is because colons are filtered out from the path here:
bwapi/bwapi/BWAPI/Source/BWAPI/GameEvents.cpp
Lines 394 to 395 in 770b0c3
| // Remove illegal characters | |
| boost::algorithm::erase_all_regex(pathStr, boost::regex("[[:cntrl:]?*<|>\":]")); |
Do we want to still do this guarding against bad filenames? It's not the only possible error, you could get an access denied as well. If we want catch these errors and default to e.g. LastReplay.rep and write a message to std::cerr, I think we should do that here:
bwapi/bwapi/BWAPI/Source/Detours.cpp
Line 275 in 770b0c3
| return CreateFileProc( getReplayName(fileName).c_str(), dwDesiredAccess, dwShareMode, lpSecurityAttributes, dwCreationDisposition, dwFlagsAndAttributes, hTemplateFile); |
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels