File tree 2 files changed +18
-17
lines changed
java/client/src/org/openqa/selenium/os
2 files changed +18
-17
lines changed Original file line number Diff line number Diff line change @@ -125,11 +125,11 @@ public void waitFor() {
125
125
}
126
126
127
127
public void waitFor (long timeout ) {
128
- try {
129
- process .waitFor (timeout );
130
- } catch (InterruptedException e ) {
131
- throw new WebDriverException (e );
132
- }
128
+ try {
129
+ process .waitFor (timeout );
130
+ } catch (InterruptedException e ) {
131
+ throw new WebDriverException (e );
132
+ }
133
133
}
134
134
135
135
public boolean isSuccessful () {
Original file line number Diff line number Diff line change @@ -133,20 +133,21 @@ public int destroy() {
133
133
public void waitFor () throws InterruptedException {
134
134
handler .waitFor ();
135
135
}
136
-
136
+
137
137
public void waitFor (long timeout ) throws InterruptedException {
138
- long until = System .currentTimeMillis () + timeout ;
139
- boolean timedOut = true ;
140
- while (System .currentTimeMillis () < until ) {
141
- if (handler .hasResult ()){
142
- timedOut = false ;
143
- break ;
144
- }
145
- Thread .sleep (50 );
138
+ long until = System .currentTimeMillis () + timeout ;
139
+ boolean timedOut = true ;
140
+ while (System .currentTimeMillis () < until ) {
141
+ if (handler .hasResult ()) {
142
+ timedOut = false ;
143
+ break ;
146
144
}
147
- if (timedOut ){
148
- throw new InterruptedException (String .format ("Process timed out after waiting for %d ms." ,timeout ) );
149
- }
145
+ Thread .sleep (50 );
146
+ }
147
+ if (timedOut ) {
148
+ throw new InterruptedException (
149
+ String .format ("Process timed out after waiting for %d ms." , timeout ));
150
+ }
150
151
}
151
152
152
153
public boolean isRunning () {
You can’t perform that action at this time.
0 commit comments