logging parameters passed to logging code

> Hi all,

I am the process of writing a logging function that will take three fixed
parameters and the upto 22 other parameters.

What is the fastest way to store the 22 optional parameters, which vary
depending on which or specific api calls is being logged.
I thought of coping the stack area to our data storage area, but may not
be portable to other c compilers / Unix systems
Comments on this idea ?

To make it portable would it be better to create structures for each of
the 22 parameter types as used in each api and then cast this to a the
data area filling the parameters using (struct *)pDataArea->struct member
= passed param;

example logging call

log_reset_hardware(int a, int b, int c, upto 22 optional parameters);

Robert Fernando
Tel: +44 (0) 7799 84 1374
Fax: +44 (0) 870 133 1992
work Email: xxxxx@anitetelecoms.com
personal email xxxxx@bigfoot.com
NB only read at home.

Personal views not necessarily those of
Anite Telecoms Limited Registered in England No. 1721900 Registered
Office: 100 Longwater Avenue, GreenPark, Reading, Berkshire RG2 6GP,
United Kingdom