On Thu, May 29, 2008 at 3:40 PM, Dan Pascu <[EMAIL PROTECTED]> wrote: > On Thursday 29 May 2008, Ovidiu Sas wrote: >> Hello Dan, >> >> Are you refering to: >> static struct dlg_cb_params params = {NULL, DLG_DIR_NONE, NULL, NULL}; >> ? > > Yes, that's the one. > >> >> It was modeled after: >> static struct tmcb_params params = {0,0,0,0,0,0}; >> from t_hooks.c. > > The fact that TM does it, is not an argument in favor of doing it. Using > global variables with not good reason can lead to subtle and hard to > track bugs. Not to mention that functions using globals are not reentrant > and in case we want to change OpenSER to use an asynchronous reactor > based design (which is a must for properly supporting TCP/TLS), we will > have big troubles from such globals when doing context switching.
Fell free to change it in this case. I have no objections. And maybe the same change should also be applied to the tm module. Ovidiu _______________________________________________ Devel mailing list Devel@lists.openser.org http://lists.openser.org/cgi-bin/mailman/listinfo/devel