From: Karthik Gopalakrishnan (gopalakk_at_cse.ohio-state.edu)
Date: Thu Mar 05 2009 - 09:56:29 PST
Hi Paul. I see that the CR Callback function can accept one void * argument. However, I don't see a 'proper' way to pass data to my application's callback function when I do a 'cr_checkpoint'. It will be nice if I could do a 'cr_checkpoint [options] ID arg1 arg2 ... argN' with arg[1..N] being passed to the registered callbacks, maybe as 'char **args' & args[N] = NULL. The definition of the callback could be changed to "typedef int (*cr_callback_t)(char **, void *)". I admit I have not thought this through, but I feel something like this will be pretty useful. Currently, I have a wrapper that writes the parameters to some tmp file before calling cr_checkpoint and I get my callback function to read the arguments off that file. I'll be grateful if you could suggest a better way for me to achieve this, in the current scenario. Thanks & Regards, Karthik