Skip to content

Commit fc8b733

Browse files
jisedlacthurka
authored andcommitted
Bugfix - make sure there's no whitespace noise/endline when reading processes using jps
1 parent 7c2ae07 commit fc8b733

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

integrations/vscode/src/runningProcesses.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ export async function getUsingJps(jpsPath: string, command: string = '-v'): Prom
113113
lines.forEach(line => {
114114
const index = line.trim().indexOf(' ');
115115
if (index >= 0) {
116-
parts.push({ pid: Number.parseInt(line.slice(0, index)), displayName: line.slice(index + 1, line.length) });
116+
parts.push({ pid: Number.parseInt(line.slice(0, index)), displayName: line.slice(index + 1, line.length).trim() });
117117
} else {
118118
parts.push({ pid: Number.parseInt(line), displayName: '' });
119119
}

0 commit comments

Comments
 (0)