Skip to content

Commit 03a0d3f

Browse files
authored
Name the ReadKey thread for debug purpose (#1313)
1 parent fcb2f74 commit 03a0d3f

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

PSReadLine/ReadLine.cs

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -541,14 +541,14 @@ private string InputLoop()
541541
}
542542
if (moveToLineCommandCount == _moveToLineCommandCount)
543543
{
544-
_moveToLineCommandCount = 0;
545-
546-
if (InViCommandMode() && moveToEndOfLineCommandCount == _moveToEndOfLineCommandCount)
547-
{
548-
// the previous command was neither a "move to end of line" command
549-
// nor a "move to line" command. In that case, the desired column
550-
// number will be computed from the current position on the logical line.
551-
544+
_moveToLineCommandCount = 0;
545+
546+
if (InViCommandMode() && moveToEndOfLineCommandCount == _moveToEndOfLineCommandCount)
547+
{
548+
// the previous command was neither a "move to end of line" command
549+
// nor a "move to line" command. In that case, the desired column
550+
// number will be computed from the current position on the logical line.
551+
552552
_moveToLineDesiredColumn = -1;
553553
}
554554
}
@@ -844,7 +844,7 @@ private void DelayedOneTimeInitialize()
844844
};
845845
}
846846

847-
_singleton._readKeyThread = new Thread(_singleton.ReadKeyThreadProc) {IsBackground = true};
847+
_singleton._readKeyThread = new Thread(_singleton.ReadKeyThreadProc) {IsBackground = true, Name = "PSReadLine ReadKey Thread"};
848848
_singleton._readKeyThread.Start();
849849
}
850850

0 commit comments

Comments
 (0)