← Commit list

90b9f51458

Daniel Stenberg
Daniel Stenberg
2026-03-17
SUCCESS Duration: 295s

Subject

tool_operate: fix minor memory-leak on early error

Binary

No binary (build failed)

Architecture & Compiler Flags

Architecture: x86_64-linux-gnu Compiler: gcc (Ubuntu 11.4.0-1ubuntu1~22.04.3) 11.4.0

—

Build Log

(log yok)

Commit Diff GitHub →

src/tool_operate.c+1 -2
@@ -2296,7 +2296,6 @@ CURLcode operate(int argc, argv_item_t argv[])
if(found_curlrc) {
/* After parse_args so notef knows the verbosity */
notef("Read config file from '%s'", curlrc_path);
- curlx_free(curlrc_path);
}
if(err) {
result = CURLE_OK;
@@ -2394,7 +2393,7 @@ CURLcode operate(int argc, argv_item_t argv[])
errorf("out of memory");
}
}
-
+ curlx_free(curlrc_path);
varcleanup();
return result;