Quote input when adding breakpoint

File path and line number are now double quoted when specified explicitly. Before only when using raw input was it double quoted.
This commit is contained in:
Alex Sadler 2016-11-14 17:04:02 +00:00 committed by GitHub
commit f0c30a91b0

View file

@ -468,7 +468,7 @@ export class MI2 extends EventEmitter implements IBackend {
if (breakpoint.raw) if (breakpoint.raw)
location = '"' + escape(breakpoint.raw) + '"'; location = '"' + escape(breakpoint.raw) + '"';
else else
location = breakpoint.file + ":" + breakpoint.line; location = '"' + breakpoint.file + ":" + breakpoint.line + '"';
this.sendCommand("break-insert -f " + location).then((result) => { this.sendCommand("break-insert -f " + location).then((result) => {
if (result.resultRecords.resultClass == "done") { if (result.resultRecords.resultClass == "done") {
let bkptNum = parseInt(result.result("bkpt.number")); let bkptNum = parseInt(result.result("bkpt.number"));
@ -666,4 +666,4 @@ export class MI2 extends EventEmitter implements IBackend {
protected process: ChildProcess.ChildProcess; protected process: ChildProcess.ChildProcess;
protected stream; protected stream;
protected sshConn; protected sshConn;
} }