GUI: fix IGFD crash if a file had % on its name
This commit is contained in:
parent
c9d7b371e1
commit
e105cd588e
|
@ -3930,6 +3930,7 @@ namespace IGFD
|
|||
ImGuiSelectableFlags_SpanAllColumns | ImGuiSelectableFlags_SpanAvailWidth;
|
||||
|
||||
// TODO BUG?!
|
||||
// YES BUG: THIS JUST CRASHED FOR SOME REASON
|
||||
va_list args;
|
||||
va_start(args, vFmt);
|
||||
vsnprintf(fdi.puVariadicBuffer, MAX_FILE_DIALOG_NAME_BUFFER, vFmt, args);
|
||||
|
@ -4137,7 +4138,8 @@ namespace IGFD
|
|||
if (ImGui::TableNextColumn()) // file name
|
||||
{
|
||||
// TODO BUG?!?!?!
|
||||
needToBreakTheloop = prSelectableItem(i, infos, selected, _str.c_str());
|
||||
// YES BUG
|
||||
needToBreakTheloop = prSelectableItem(i, infos, selected, "%s", _str.c_str());
|
||||
if (needToBreakTheloop==2) escape=true;
|
||||
}
|
||||
if (ImGui::TableNextColumn()) // file type
|
||||
|
|
Loading…
Reference in New Issue