You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
could we make a change to use index rather re-using i?
For example:
/* check if new for this transfer */
int index = 0;
for(index; index < data->numsocks; index++) {
The text was updated successfully, but these errors were encountered:
An inner loop within the singlesocket() function wrongly re-used the
variable for the outer loop which then could cause an infinite
loop. Change to using a separate variable!
Reported-by: Eric Wu
Fixes#3970
(gdb) p *entry
$29 = {
list = {
head = 0x80be848,
tail = 0x80be848,
dtor = 0x0,
size = 1
},
action = 1,
socketp = 0x0,
users = 1,
readers = 1,
writers = 0
}
the loop i = 0 to MAX_SOCKSPEREASYHANDLE
https://github.com/curl/curl/blob/master/lib/multi.c#L2234
i was setting back to 0
https://github.com/curl/curl/blob/master/lib/multi.c#L2255
when entry action == comboaction will go back 1) and i = 1, 2) will set to 0 again. loop forever.
// comboaction = 1, entry->action = 1
https://github.com/curl/curl/blob/master/lib/multi.c#L2306
could we make a change to use index rather re-using i?
For example:
/* check if new for this transfer */
int index = 0;
for(index; index < data->numsocks; index++) {
The text was updated successfully, but these errors were encountered: