- pass-test
td1 = td_startTD2([]()->void{
try
{
while (1)
{
uv_work_t *req = new uv_work_t();
req->data = NULL;
int status = uv_queue_work(
uv_default_loop(),
req,
[](uv_work_t* req)->void{
},
[](uv_work_t* req, int status)->void{
HandleScope scope;
wstring jsCode = L"io.cw('123')";
v8::Local<v8::Script> script = v8::Script::Compile(toV8String(jsCode));
v8::Handle<v8::Value> result = script->Run();
});
td_sleep(10*1000);
}
}
catch (boost::thread_interrupted&)
{
io_cw("td1 exit ok.");
}
});
On Tuesday, November 19, 2013 5:09:35 PM UTC+8, KOS KOS wrote:
>
> Please show the full code sample that works for you.
>
> Четвер, 26 вересня 2013 р. 10:43:50 UTC+3 користувач Ashish Negi написав:
>>
>> @Ben Thank you. It took me a while to understand what did you meant
>> "require() is not in global function".
>>
>> @Jorge Thank you too. After reading your post it hit me that i should do
>> *global.request
>> = request;*
>>
>> That just solves the problem that Ben has said. And it is working now.
>>
>> Last question though, Is there any side-effects of this ?
>>
>
--
--
Job Board: http://jobs.nodejs.org/
Posting guidelines:
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en
---
You received this message because you are subscribed to the Google Groups
"nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.