>An alternative not mentioned is to make the callback type have a
>variable number of arguments, like
This requires all callbacks to be written as varargs programs.
(It often also means a different, slower, calling sequence.)
>This would still break existing code, but which would allow for more
>or less arbitrary parameters to callbacks.
The "void*" approach does this as well. You create a struct that has the
data you need, pass the address of that the void*, and in the callback cast
the void* back to your custom struct. This is common practice (e.g.,
X "context", pthread_create "arg" parameter, Win32 ulParam (sic :)) and
while it's not typesafe, it is the best alternative.
/r$
______________________________________________________________________
OpenSSL Project http://www.openssl.org
Development Mailing List [EMAIL PROTECTED]
Automated List Manager [EMAIL PROTECTED]