Skip to content
This repository was archived by the owner on Oct 16, 2020. It is now read-only.

Commit 8063942

Browse files
close #296: ArgumentNullException when debugging and pdb points to missing file
+ show StackFrames without file name as unreachable in CallStackPad
1 parent a8a3391 commit 8063942

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

src/AddIns/Debugger/Debugger.AddIn/Pads/CallStackPad.cs

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,9 @@ CallStackItem CreateItem(StackFrame frame, ref bool previousItemIsExternalMethod
150150
{
151151
bool showExternalMethods = DebuggingOptions.Instance.ShowExternalMethods;
152152
var symSource = WindowsDebugger.PdbSymbolSource;
153-
bool hasSymbols = symSource.Handles(frame.MethodInfo) && !symSource.IsCompilerGenerated(frame.MethodInfo);
153+
bool hasSymbols = symSource.Handles(frame.MethodInfo)
154+
&& !symSource.IsCompilerGenerated(frame.MethodInfo)
155+
&& frame.NextStatement != null && !string.IsNullOrWhiteSpace(frame.NextStatement.Filename);
154156
if (showExternalMethods || hasSymbols) {
155157
// Show the method in the list
156158
previousItemIsExternalMethod = false;

0 commit comments

Comments
 (0)