Skip to content
This repository was archived by the owner on Apr 22, 2023. It is now read-only.
This repository was archived by the owner on Apr 22, 2023. It is now read-only.

debugger: TypeError: Cannot call method 'replace' of undefined #6453

Closed
@bnoordhuis

Description

@bnoordhuis
$ git rev-list --abbrev-commit HEAD^..HEAD
d2a6002
$ out/Release/node debug -p $(pgrep node)
connecting to port 5858... ok
debug> setBreakpoint(20)
Warning: script 'undefined' was not loaded yet.

_debugger.js:1396
      var escapedPath = script.replace(/([/\\.?*()^${}|[\]])/g, '\\$1');
                               ^
TypeError: Cannot call method 'replace' of undefined
    at Interface.setBreakpoint (_debugger.js:1396:32)
    at repl:1:1
    at Object.exports.runInContext (vm.js:60:17)
    at Interface.controlEval (_debugger.js:969:21)
    at REPLServer.b [as eval] (domain.js:251:18)
    at Interface.<anonymous> (repl.js:277:12)
    at Interface.EventEmitter.emit (events.js:103:17)
    at Interface._onLine (readline.js:194:10)
    at Interface._line (readline.js:523:8)
    at Interface._ttyWrite (readline.js:798:14)

/cc @bajtos - seems to have been introduced in 5db936d.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions