Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion loc/lci/OpenFolderSchema.json.lci
Original file line number Diff line number Diff line change
Expand Up @@ -408,7 +408,7 @@
</Item>
<Item ItemId=";debugExtensions.cppdbg.schema.definitions.cpp_schema.properties.debuginfod.properties.enabled.description" ItemType="0" PsrId="306" InstFlg="true" Leaf="true">
<Str Cat="Text">
<Val><![CDATA[If true (default), GDB's debuginfod support is enabled. Set to false to disable debuginfod, which can prevent GDB from hanging when debuginfod servers are unavailable.]]></Val>
<Val><![CDATA[If true, GDB's debuginfod support is enabled. Set to true to enable debuginfod. Default is false.]]></Val>
</Str>
<Disp Icon="Str" />
<Cmts>
Expand Down
2 changes: 1 addition & 1 deletion src/MICore/JsonLaunchOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -324,7 +324,7 @@ public enum UnknownBreakpointHandling
public partial class DebuginfodSettings
{
/// <summary>
/// If true (default), GDB's debuginfod support is enabled.
/// If true, GDB's debuginfod support is enabled. Default is false.
/// </summary>
[JsonProperty("enabled")]
public bool? Enabled { get; set; }
Expand Down
6 changes: 3 additions & 3 deletions src/MICore/LaunchOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1224,10 +1224,10 @@ public UnknownBreakpointHandling UnknownBreakpointHandling
}
}

private bool _enableDebuginfod = true;
private bool _enableDebuginfod = false;

/// <summary>
/// If true (default), GDB's debuginfod support is enabled.
/// If true, GDB's debuginfod support is enabled. Default is false.
/// </summary>
public bool EnableDebuginfod
{
Expand Down Expand Up @@ -1912,7 +1912,7 @@ protected void InitializeCommonOptions(Json.LaunchOptions.BaseOptions options)
}

this.UnknownBreakpointHandling = options.UnknownBreakpointHandling ?? UnknownBreakpointHandling.Throw;
this.EnableDebuginfod = options.Debuginfod?.Enabled ?? true;
this.EnableDebuginfod = options.Debuginfod?.Enabled ?? false;
int debuginfodTimeout = options.Debuginfod?.Timeout ?? 30;
this.DebuginfodTimeout = debuginfodTimeout >= 0 ? debuginfodTimeout : 30;
}
Expand Down
6 changes: 3 additions & 3 deletions src/MICore/LaunchOptions.xsd
Original file line number Diff line number Diff line change
Expand Up @@ -207,11 +207,11 @@
</xs:documentation>
</xs:annotation>
</xs:attribute>
<xs:attribute name="EnableDebuginfod" type="xs:boolean" use="optional" default="true">
<xs:attribute name="EnableDebuginfod" type="xs:boolean" use="optional" default="false">
<xs:annotation>
<xs:documentation>
If true (default), GDB's debuginfod support is enabled, allowing automatic downloading of debug symbols.
Set to false to disable debuginfod, which can prevent GDB from hanging when debuginfod servers are unavailable.
If true, GDB's debuginfod support is enabled, allowing automatic downloading of debug symbols.
Set to true to enable debuginfod. Default is false.
</xs:documentation>
</xs:annotation>
</xs:attribute>
Expand Down
12 changes: 6 additions & 6 deletions src/MICore/LaunchOptions.xsd.types.designer.cs

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions src/MIDebugEngine/Engine.Impl/DebuggedProcess.cs
Original file line number Diff line number Diff line change
Expand Up @@ -628,6 +628,10 @@ private async Task<List<LaunchCommand>> GetInitializeCommands()
{
commands.Add(new LaunchCommand("set debuginfod enabled on", ignoreFailures: true));
}
else
{
commands.Add(new LaunchCommand("set debuginfod enabled off", ignoreFailures: true));
}
}

// When user specifies loading directives then the debugger cannot auto load symbols, the MIEngine must intervene at each solib-load event and make a determination
Expand Down
6 changes: 3 additions & 3 deletions src/MIDebugPackage/OpenFolderSchema.json
Original file line number Diff line number Diff line change
Expand Up @@ -197,12 +197,12 @@
"debuginfod": {
"type": "object",
"description": "Controls GDB's debuginfod behavior for automatic downloading of debug symbols.",
"default": { "enabled": true, "timeout": 30 },
"default": { "enabled": false, "timeout": 30 },
"properties": {
"enabled": {
"type": "boolean",
"description": "If true (default), GDB's debuginfod support is enabled. Set to false to disable debuginfod, which can prevent GDB from hanging when debuginfod servers are unavailable.",
"default": true
"description": "If true, GDB's debuginfod support is enabled. Set to true to enable debuginfod. Default is false.",
"default": false
},
"timeout": {
"type": "integer",
Expand Down
3 changes: 2 additions & 1 deletion test/CppTests/Tests/DebuginfodTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,8 @@ public void DebuginfodDisabledDoesNotHang(ITestSettings settings)
{
string logContent = File.ReadAllText(engineLogPath);
this.Comment("Verifying debuginfod was NOT enabled in GDB");
Assert.DoesNotContain("debuginfod enabled", logContent);
Assert.DoesNotContain("set debuginfod enabled on", logContent);
Assert.Contains("set debuginfod enabled off", logContent);
}
}
finally
Expand Down
Loading