tool_operate: keep the progress meter for --out-null

Fixes #18607
Closes #18609
This commit is contained in:
Daniel Stenberg 2025-09-19 08:47:15 +02:00
parent 9f18cb6544
commit 9fb8d567ca
No known key found for this signature in database
GPG key ID: 5CC908FDB71E12C2

View file

@ -1277,8 +1277,8 @@ static CURLcode single_transfer(struct OperationConfig *config,
config->resume_from = -1; /* -1 will then force get-it-yourself */
}
if(output_expected(per->url, per->uploadfile) && outs->stream &&
isatty(fileno(outs->stream)))
if(!outs->out_null && output_expected(per->url, per->uploadfile) &&
outs->stream && isatty(fileno(outs->stream)))
/* we send the output to a tty, therefore we switch off the progress
meter */
per->noprogress = global->noprogress = global->isatty = TRUE;