/// <summary>If available, will read CrashContext.runtime-xml.</summary> public void ReadCrashContextIfAvailable() { try { //\\epicgames.net\Root\Projects\Paragon\QA_CrashReports bool bHasCrashContext = HasCrashContextFile(); if (bHasCrashContext) { //_CrashContext = FGenericCrashContext.FromFile(SitePath + GetCrashContextUrl()); _CrashContext = Settings.Default.DownloadFromS3 ? FGenericCrashContext.FromUrl(GetCrashContextUrl()) : null; bool bTest = _CrashContext != null && !string.IsNullOrEmpty(_CrashContext.PrimaryCrashProperties.FullCrashDumpLocation); if (bTest) { _bUseFullMinidumpPath = true; //Some temporary code to redirect to the new file location for fulldumps for paragon. //Consider removing this once fulldumps stop appearing in the old location. if (_CrashContext.PrimaryCrashProperties.FullCrashDumpLocation.ToLower() .Contains("\\\\epicgames.net\\root\\dept\\gameqa\\paragon\\paragon_launcherCrashdumps")) { //Files from old versions of the client may end up in the old location. Check for files there first. if (!System.IO.Directory.Exists(_CrashContext.PrimaryCrashProperties.FullCrashDumpLocation)) { var suffix = _CrashContext.PrimaryCrashProperties.FullCrashDumpLocation.Substring("\\\\epicgames.net\\root\\dept\\gameqa\\paragon\\paragon_launcherCrashdumps".Length); _CrashContext.PrimaryCrashProperties.FullCrashDumpLocation = String.Format("\\\\epicgames.net\\Root\\Projects\\Paragon\\QA_CrashReports{0}", suffix); //If the file doesn't exist in the new location either then don't use the full minidump path. _bUseFullMinidumpPath = System.IO.Directory.Exists(_CrashContext.PrimaryCrashProperties.FullCrashDumpLocation); } } //End of temporary code. FLogger.Global.WriteEvent("ReadCrashContextIfAvailable " + _CrashContext.PrimaryCrashProperties.FullCrashDumpLocation + " is " + _bUseFullMinidumpPath); } } } catch (Exception Ex) { Debug.WriteLine("Exception in ReadCrashContextIfAvailable: " + Ex.ToString()); } }
/// <summary>If available, will read CrashContext.runtime-xml.</summary> public void ReadCrashContextIfAvailable() { try { //\\epicgames.net\Root\Projects\Paragon\QA_CrashReports bool bHasCrashContext = HasCrashContextFile(); Plugins = new List <string>(); if (bHasCrashContext) { //_CrashContext = FGenericCrashContext.FromFile(SitePath + GetCrashContextUrl()); _CrashContext = FGenericCrashContext.FromUrl(GetCrashContextUrl()); bool bTest = _CrashContext != null && !string.IsNullOrEmpty(_CrashContext.PrimaryCrashProperties.FullCrashDumpLocation); if (bTest) { _bUseFullMinidumpPath = true; //Some temporary code to redirect to the new file location for fulldumps for paragon. //Consider removing this once fulldumps stop appearing in the old location. if (_CrashContext.PrimaryCrashProperties.FullCrashDumpLocation.ToLower() .Contains("\\\\epicgames.net\\root\\dept\\gameqa\\paragon\\paragon_launcherCrashdumps")) { //Files from old versions of the client may end up in the old location. Check for files there first. if (!System.IO.Directory.Exists(_CrashContext.PrimaryCrashProperties.FullCrashDumpLocation)) { var suffix = _CrashContext.PrimaryCrashProperties.FullCrashDumpLocation.Substring("\\\\epicgames.net\\root\\dept\\gameqa\\paragon\\paragon_launcherCrashdumps".Length); _CrashContext.PrimaryCrashProperties.FullCrashDumpLocation = String.Format("\\\\epicgames.net\\Root\\Projects\\Paragon\\QA_CrashReports{0}", suffix); //If the file doesn't exist in the new location either then don't use the full minidump path. _bUseFullMinidumpPath = System.IO.Directory.Exists(_CrashContext.PrimaryCrashProperties.FullCrashDumpLocation); } } //End of temporary code. FLogger.Global.WriteEvent("ReadCrashContextIfAvailable " + _CrashContext.PrimaryCrashProperties.FullCrashDumpLocation + " is " + _bUseFullMinidumpPath); } if (_CrashContext.UntypedEnabledPlugins != null) { XmlNode[] nodes = _CrashContext.UntypedEnabledPlugins as XmlNode[]; if (nodes != null) { foreach (var node in nodes) { try { dynamic data = Json.Decode(node.InnerText); String printName = data.FriendlyName + " " + data.VersionName; System.Diagnostics.Debug.WriteLine(printName); Plugins.Add(printName); } catch (Exception e) { Debug.WriteLine("Error trying to add a plugin entry: " + e.ToString()); } } } } } } catch (Exception Ex) { Debug.WriteLine("Exception in ReadCrashContextIfAvailable: " + Ex.ToString()); } }