From f138177b92b2db962de959f1311726bd4f67d7cd Mon Sep 17 00:00:00 2001 From: Harry Sintonen Date: Thu, 13 Feb 2025 20:33:33 +0200 Subject: [PATCH] docs: add FD_ZERO to curl_multi_fdset example While the examples are not intended to complete applications this is quite relevant for the correct function of the code. Closes #16325 --- docs/libcurl/curl_multi_fdset.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/libcurl/curl_multi_fdset.md b/docs/libcurl/curl_multi_fdset.md index d43663dd90..1396738014 100644 --- a/docs/libcurl/curl_multi_fdset.md +++ b/docs/libcurl/curl_multi_fdset.md @@ -100,6 +100,10 @@ int main(void) /* call curl_multi_perform() */ + FD_ZERO(&fdread); + FD_ZERO(&fdwrite); + FD_ZERO(&fdexcep); + /* get file descriptors from the transfers */ mc = curl_multi_fdset(multi, &fdread, &fdwrite, &fdexcep, &maxfd); -- 2.47.3