alibaba/wax

Wax get wax_panic crash when getting called heavily.

lovecactus opened this issue · 2 comments

There random SEGV_ACCERR while application frequently calling wax. Please help.

Here is the dump:

Exception Type: SIGSEGV
Exception Codes: SEGV_ACCERR at 0x7865646e69206f8c
Crashed Thread: 1

Thread 0:
0 libunwind.dylib 0x00000001813efb74 0x1813ec000 + 15220
1 libunwind.dylib 0x00000001813eda2c 0x1813ec000 + 6700
2 libunwind.dylib 0x00000001813f0b20 0x1813ec000 + 19232
3 libc++abi.dylib 0x0000000180dc284c 0x180da8000 + 108620
4 libobjc.A.dylib 0x0000000180dd0094 0x180dc8000 + 32916
5 CoreFoundation 0x00000001817615c0 0x18163c000 + 1201600
6 Application1 0x0000000100c3efe0 wax_panic (wax.m:71)
7 Application1 0x0000000100c27e64 luaD_throw (ldo.c:104)
8 Application1 0x0000000100c27a98 luaG_runerror (ldebug.c:636)
9 Application1 0x0000000100c277d8 luaG_typeerror (ldebug.c:578)
10 Application1 0x0000000100c36fb4 luaV_settable (lvm.c:151)
11 Application1 0x0000000100c209cc lua_setfield (lapi.c:666)
12 Application1 0x0000000100c21e94 luaL_openlib (lauxlib.c:260)
13 Application1 0x0000000100c22930 luaopen_base (lbaselib.c:650)
14 Application1 0x0000000100c28404 luaD_precall (ldo.c:319)
15 Application1 0x0000000100c28884 luaD_call (ldo.c:376)
16 Application1 0x0000000100c20d74 lua_call (lapi.c:783)
17 Application1 0x0000000100c2aaac luaL_openlibs (linit.c:32)
18 Application1 0x0000000100c3f084 wax_setup (wax.m:88)
19 Application1 0x0000000100c3f4c4 wax_start (wax.m:101)
20 Application1 0x00000001004ae200 -TKPatchManager runWithFilePath:
21 libdispatch.dylib 0x00000001811b5630 0x1811b4000 + 5680
22 libdispatch.dylib 0x00000001811b55f0 0x1811b4000 + 5616
23 libdispatch.dylib 0x00000001811bacf8 0x1811b4000 + 27896
24 CoreFoundation 0x0000000181718bb0 0x18163c000 + 904112
25 CoreFoundation 0x0000000181716a18 0x18163c000 + 895512
26 CoreFoundation 0x0000000181645680 0x18163c000 + 38528
27 GraphicsServices 0x0000000182b54088 0x182b48000 + 49288
28 UIKit 0x00000001864bcd90 0x186440000 + 511376
29 Application1 0x000000010012b42c main (main.m:22)
30 ??? 0x00000001811e68b8 0x0 + 0

Thread 1 Crashed:
0 Application1 0x0000000100c34f20 luaH_getstr (ltable.c:458)
1 Application1 0x0000000100c20a40 lua_rawset (lapi.c:677)
2 Application1 0x0000000100cb904c wax_instance_pushUserdataTable (wax_instance.m:191)
3 Application1 0x0000000100cb8f3c wax_instance_pushUserdata (wax_instance.m:267)
4 Application1 0x0000000100cb9370 wax_instance_pushFunction (wax_instance.m:229)
5 Application1 0x0000000100cba784 hookForwardInvocation (wax_instance.m:607)
6 CoreFoundation 0x00000001817653e8 0x18163c000 + 1217512
7 CoreFoundation 0x000000018166968c 0x18163c000 + 185996
8 Foundation 0x00000001820e78ac 0x182030000 + 751788
9 Foundation 0x000000018203cafc 0x182030000 + 51964
10 Foundation 0x00000001820eaa30 0x182030000 + 764464
11 Application1 0x0000000100a1abd8 -MTLModel dictionaryValue
12 Application1 0x0000000100a19ea0 -MTLModel(NSCoding) encodeWithCoder:
13 Foundation 0x000000018209b3f0 0x182030000 + 439280
14 Foundation 0x00000001820a2258 0x182030000 + 467544
15 Application1 0x0000000100545f6c -ApplicationConfig SaveForumConfigModelToUserReference:ForumID:
16 Application1 0x0000000100546720 -ApplicationConfig ArchiveForumConfigModel:ForumID:
17 Application1 0x000000010054b1b8 -ApplicationConfig ParseForumConfig:ForumID:
18 Application1 0x00000001005481ac -ApplicationConfig ParseDirectoryConfig:
19 Application1 0x00000001003c6f08 -TKAccountsManager updateAccountsFromServerDictList:forums:
20 Application1 0x00000001005ac7ec __66-[TKIDManager asyncUserInfoAndGetAccountInfo:failedBlock:]_block_invoke_2 (TKIDManager.m:331)
21 libdispatch.dylib 0x00000001811b5630 0x1811b4000 + 5680
22 libdispatch.dylib 0x00000001811b55f0 0x1811b4000 + 5616
23 libdispatch.dylib 0x00000001811c3a88 0x1811b4000 + 64136
24 libdispatch.dylib 0x00000001811c3224 0x1811b4000 + 61988
25 libsystem_pthread.dylib 0x00000001813c9470 0x1813c8000 + 5232
26 libsystem_pthread.dylib 0x00000001813c9020 0x1813c8000 + 4128

Anybody help? Let me know if any additional info needed.

you should just call wax_setup once on main thread.