examples: check more errors, fix cleanups, scope variables

Inspired by Joshua's report on examples.

Closes #19055
This commit is contained in:
Viktor Szakats 2025-10-13 22:57:01 +02:00
parent 61dcb56743
commit 64ed2ea196
No known key found for this signature in database
GPG key ID: B5ABD165E2AEF201
42 changed files with 874 additions and 785 deletions

View file

@ -70,7 +70,6 @@ static int xferinfo(void *p,
int main(void)
{
CURL *curl;
struct myprogress prog;
CURLcode res = curl_global_init(CURL_GLOBAL_ALL);
if(res)
@ -78,6 +77,8 @@ int main(void)
curl = curl_easy_init();
if(curl) {
struct myprogress prog;
prog.lastruntime = 0;
prog.curl = curl;