Skip to content

A variadic function that stores its own next argument is where the argument list starts: libcurl's curl_share_setopt (D213, #3124) - #3561

Merged
ehartford merged 1 commit into
mainfrom
variadic-own-list
Nov 23, 2026
Merged

ehartford merged 1 commit into
mainfrom
variadic-own-list

Conversation

@ehartford

Copy link
Copy Markdown
Contributor

A small extension of #3556.

The variadic rule walked from the storing function up its callers to the functions that start the argument list. The simplest shape was not covered: a public variadic function that reads its own list and stores the argument itself, as libcurl's curl_share_setopt does for its lock callbacks (share->lockfunc = va_arg(param, curl_lock_function)). The list is then no parameter of the storing function, and the store was reported as not under a case of a switch on a parameter.

Such a function is itself where the list starts: its own facts are the ones asked for case K, and the package's own calls of it are the ones checked.

Test: a direct case in conan_facade_callback_variadic_test.

Battery green (503 s). :release-checks: the run chained after the battery reported a failure whose log I did not keep (the output was piped through a filter); three reruns on the same sources are green, and I could not reproduce it. Named here so it is not lost; release-check output goes to a file from now on.

…gument list starts: libcurl's curl_share_setopt (D213, #3124)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant