Skip to content
Open
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
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ internal static void ApplyContextSwitches(IAppContextSwitchOverridesSection appC
SqlClientEventSource.Log.TryTraceEvent("<sc.{0}.{1}|INFO> Entry point.", TypeName, methodName);
if (appContextSwitches != null)
{
ApplySwitchValues(appContextSwitches.Value?.Split('=', ';'));
ApplySwitchValues(appContextSwitches.Value?.Trim(';')?.Split('=', ';'));
}

SqlClientEventSource.Log.TryTraceEvent("<sc.{0}.{1}|INFO> Exit point.", TypeName, methodName);
Expand All @@ -39,7 +39,7 @@ private static bool ApplySwitchValues(string[] switches)
if (switches == null || switches.Length == 0 || switches.Length % 2 == 1)
{ return false; }

for (int i = 0; i < switches.Length / 2; i++)
for (int i = 0; i < switches.Length; i += 2)
{
try
{
Expand Down