wallet不再使用default loop
This commit is contained in:
parent
d2df792068
commit
82f2028636
1
.gitignore
vendored
1
.gitignore
vendored
@ -14,3 +14,4 @@
|
|||||||
.cxx
|
.cxx
|
||||||
local.properties
|
local.properties
|
||||||
/app/release/
|
/app/release/
|
||||||
|
restart.sh
|
||||||
|
@ -49,7 +49,9 @@ NS_CC_BEGIN
|
|||||||
|
|
||||||
void init_libuv_async_handle(uv_async_t *async) {
|
void init_libuv_async_handle(uv_async_t *async) {
|
||||||
memset(async, 0, sizeof(uv_async_t));
|
memset(async, 0, sizeof(uv_async_t));
|
||||||
uv_loop_t *loop = uv_default_loop();
|
// uv_loop_t *loop = uv_default_loop();
|
||||||
|
uv_loop_t* loop = (uv_loop_t*)malloc(sizeof(uv_loop_t));
|
||||||
|
uv_loop_init(loop);
|
||||||
uv_async_init(loop, async, cocos2d::flush_tasks_in_server_loop_cb);
|
uv_async_init(loop, async, cocos2d::flush_tasks_in_server_loop_cb);
|
||||||
async->data = new AsyncTaskData();
|
async->data = new AsyncTaskData();
|
||||||
uv_run(loop, UV_RUN_DEFAULT);
|
uv_run(loop, UV_RUN_DEFAULT);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user