Skip to content

Commit cc58a4e

Browse files
committed
[java] include the exit code to the error message of a failed driver startup
1 parent 623c4aa commit cc58a4e

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

java/src/org/openqa/selenium/remote/service/DriverService.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -242,8 +242,10 @@ public void start() throws IOException {
242242
processFinished.cancel(true);
243243
break;
244244
case PROCESS_DIED:
245+
int exitValue = process.exitValue();
245246
process = null;
246-
throw new WebDriverException("Driver server process died prematurely.");
247+
throw new WebDriverException(
248+
"Driver server process died prematurely, exit value: " + exitValue);
247249
case PROCESS_IS_ACTIVE:
248250
process.shutdown();
249251
throw new WebDriverException("Timed out waiting for driver server to bind the port.");

0 commit comments

Comments
 (0)