diff --git a/renderdocui/Code/Helpers.cs b/renderdocui/Code/Helpers.cs index d7750e82f..6e4e3c316 100644 --- a/renderdocui/Code/Helpers.cs +++ b/renderdocui/Code/Helpers.cs @@ -271,7 +271,19 @@ namespace renderdocui.Code foreach (var n in names) { - if(String.Compare(Path.GetFullPath(n), myJSON, StringComparison.CurrentCultureIgnoreCase) == 0) + string fullpath; + + try + { + fullpath = Path.GetFullPath(n); + } + catch (Exception) + { + // invalid path or similar + fullpath = ""; + } + + if(String.Compare(fullpath, myJSON, StringComparison.CurrentCultureIgnoreCase) == 0) { thisRegistered = true; }