Skip to content

Commit c95ca8d

Browse files
committed
runtests: use the correct fd after select
The code was using the wrong fd when determining which runner was ready with a response. Ref: curl#10818 Closes curl#11160
1 parent 9f87dee commit c95ca8d

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

tests/runner.pm

+2-2
Original file line numberDiff line numberDiff line change
@@ -1226,7 +1226,7 @@ sub runnerar {
12261226
}
12271227

12281228
###################################################################
1229-
# Returns runnder ID if a response from an async call is ready
1229+
# Returns runner ID if a response from an async call is ready
12301230
# argument is 0 for nonblocking, undef for blocking, anything else for timeout
12311231
# Called by controller
12321232
sub runnerar_ready {
@@ -1248,7 +1248,7 @@ sub runnerar_ready {
12481248
# TODO: handle errors
12491249
if(select(my $rout=$rin, undef, undef, $blocking)) {
12501250
for my $fd (0..$maxfileno) {
1251-
if(vec($rin, $fd, 1)) {
1251+
if(vec($rout, $fd, 1)) {
12521252
return $idbyfileno{$fd};
12531253
}
12541254
}

0 commit comments

Comments
 (0)