running = multi:Perform()
When an application has found out there's data available for the multi handle or a timeout has elapsed, the
application should call this function to read/write whatever there is to read or write right now etc.
multi:Perform()
returns as soon as the reads/writes are done. This function does not require that
there actually is any data available for reading or that data can be written, it can be called just in case.
It will return the number of handles that still transfer data.
If the amount of running handles is changed from the previous call (or is less than the amount of easy handles you've added to the multi handle), you know that there is one or more transfers less "running". You can then call multi:InfoRead() to get information about each individual completed transfer, and that returned info includes CURLcode and more. If an added handle fails very quickly, it may never be counted as a running handle.
When running
is get to zero on the return of this function, there is no longer any transfers in progress.