[OpenSER-Devel] SF.net SVN: openser: [3429] trunk
Henning Westerholt
henning.westerholt at 1und1.de
Wed Dec 19 14:33:04 UTC 2007
On Wednesday 19 December 2007, Bogdan-Andrei Iancu wrote:
> Hi Henning,
>
> wouldn't be better to have the prototype exactly with the 6 parameters
> (instead of "int (*cmd_function)(struct sip_msg*, ...);" ? Just to be
> sincronized with the way the functions are called from the action.c
> (with 6 params). Otherwise I do not see any difference.
>
> Just an idea :)
Hi Bogdan,
ok, this will breaks the compilation for function that uses this function
directly from the config script:
rd_funcs.c: In function ‘shmcontact2dset’:
rd_funcs.c:274: Error: error: too few arguments to function ‘rd_acc_fct’
The signature of the function needs to be changed to have the six parameters
too. This works out of the box for the ellipse case.
char foo1, foo2, foo3, foo4;
rd_acc_fct( req, (char*)reason, acc_db_table, &foo1, &foo2, &foo3, &foo4);
This is not really pretty. But as this way of using functions directly from
the config script is not recommended at all. And i see also some other
benefits in using the prototype with the 6 parameters directly.
So i think i will change this later.
Cheers,
Henning
More information about the Devel
mailing list