mirror of
https://github.com/Microsoft/vscode
synced 2024-10-13 23:09:01 +00:00
Safer change for #25422
This commit is contained in:
parent
867468a559
commit
ce18dd018d
|
@ -235,7 +235,7 @@ export class RipgrepParser extends EventEmitter {
|
|||
this.onResult();
|
||||
}
|
||||
|
||||
this.fileMatch = new FileMatch(path.resolve(this.rootFolder, r[1]));
|
||||
this.fileMatch = new FileMatch(path.isAbsolute(r[1]) ? r[1] : path.join(this.rootFolder, r[1]));
|
||||
} else {
|
||||
// Line is empty (or malformed)
|
||||
}
|
||||
|
|
|
@ -74,7 +74,7 @@ suite('RipgrepParser', () => {
|
|||
assert.deepEqual(results[0],
|
||||
<ISerializedFileMatch>{
|
||||
numMatches: 2,
|
||||
path: path.resolve(rootFolder, 'a.txt'),
|
||||
path: path.join(rootFolder, 'a.txt'),
|
||||
lineMatches: [
|
||||
{
|
||||
lineNumber: 0,
|
||||
|
|
Loading…
Reference in a new issue