8210987: Extra newlines on Windows when running nsk jdb tests
Fix skipping over newlines Reviewed-by: dholmes, jcbeyler, amenkov
This commit is contained in:
parent
8edf8e2b03
commit
7dd0aaa430
@ -291,7 +291,7 @@ public class Jdb extends LocalProcess implements Finalizable {
|
|||||||
jdbCommand += lineSeparator;
|
jdbCommand += lineSeparator;
|
||||||
} else {
|
} else {
|
||||||
// we don't want to log the line separator
|
// we don't want to log the line separator
|
||||||
logCmd = jdbCommand.substring(0, jdbCommand.length() - 1);
|
logCmd = jdbCommand.substring(0, jdbCommand.length() - lineSeparator.length());
|
||||||
}
|
}
|
||||||
launcher.getLog().display("Sending command: " + logCmd);
|
launcher.getLog().display("Sending command: " + logCmd);
|
||||||
|
|
||||||
@ -698,7 +698,7 @@ public class Jdb extends LocalProcess implements Finalizable {
|
|||||||
int i = string.indexOf(lineSeparator, ind);
|
int i = string.indexOf(lineSeparator, ind);
|
||||||
if (i >= 0) {
|
if (i >= 0) {
|
||||||
v.add(string.substring(ind, i));
|
v.add(string.substring(ind, i));
|
||||||
ind = i + 1;
|
ind = i + lineSeparator.length();
|
||||||
} else {
|
} else {
|
||||||
v.add(string.substring(ind));
|
v.add(string.substring(ind));
|
||||||
break;
|
break;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user