I have a function as shown below:
bool setJavaScript(int time , const str::string text)
{
d->setJavaTimeOut(time, &shouldTerminate);
}
...and the function shouldTerminate is like this :
bool shouldTerminate(JSContextRef ctx, void* context)
{
}
Now, I want the variable text in setJavaScript to be accessed in shouldTerminate, how do I do that?
Both functions are in same file.
The variable text has been sent by another function from different file.
 
    