Skip to content

When in visual mode pressing 'x' twice yields an exception #24

@MarcoBuess

Description

@MarcoBuess

Oops, something went wrong.
Please report this bug with ALL the details below, including both the 'Environment' and 'Exception' sections.
Please report on GitHub: https://github.com/PowerShell/PSReadLine/issues/new?template=Bug_Report.md
Thank you!

Environment

PSReadLine: 2.1.0
PowerShell: 7.1.3
OS: Microsoft Windows 10.0.19042
BufferWidth: 269
BufferHeight: 62

Exception

System.ArgumentException: length is not valid (Parameter 'length')
   at Microsoft.PowerShell.PSConsoleReadLine.Replace(Int32 start, Int32 length, String replacement, Action`2 instigator, Object instigatorArg)
   at Microsoft.PowerShell.PSConsoleReadLine.Delete(Int32 start, Int32 length)
   at Microsoft.PowerShell.PSConsoleReadLine.DeleteCharImpl(Int32 qty, Boolean orExit)
   at Microsoft.PowerShell.PSConsoleReadLine.DeleteChar(Nullable`1 key, Object arg)
   at Microsoft.PowerShell.PSConsoleReadLine.ProcessOneKey(PSKeyInfo key, Dictionary`2 dispatchTable, Boolean ignoreIfNoAction, Object arg)
   at Microsoft.PowerShell.PSConsoleReadLine.InputLoop()
   at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics, CancellationToken cancellationToken)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions