libchewing icon indicating copy to clipboard operation
libchewing copied to clipboard

assert fail in DuplicateRecordAndInsertInterval

Open kcwu opened this issue 9 years ago • 3 comments

https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=112

reduced testcase

$ xxd -r > 112-assert-record
00000000: 743b 0674 3b06 0000 053d 0303 0041 40    t;.t;....=...A@

how to reproduce

$ ./test/stress -file 112-assert-record  -loop 1
stress: tree.c:860: RecordNode *DuplicateRecordAndInsertInterval(const RecordNode *, TreeDataType *, const int): Assertion `record' failed.

kcwu avatar Nov 23 '16 13:11 kcwu

hi kcwu, can I have the test case for this bug please?

edwin6202 avatar Oct 05 '17 11:10 edwin6202

It can be generated from xxd:

  1. Run this command
xxd -r > 112-assert-record
  1. Paste the following line:
00000000: 743b 0674 3b06 0000 053d 0303 0041 40    t;.t;....=...A@
  1. Hit enter and then Ctrl+D.

It can also be generated from base64, which is simpler:

echo dDsGdDsGAAAFPQMDAEFA | base64 -d > 112-assert-record

yan12125 avatar Oct 05 '17 13:10 yan12125

I got a quite similar error message in real life...

fcitx: tree.c:860:DuplicateRecordAndInsertInterval: 假設『record』失敗。
=========================
FCITX 4.2.9.5 -- Get Signal No.: 6
Date: try "date -d @1553520279" if you are using GNU date ***
ProcessID: 5453
fcitx(+0x145e)[0x55cc8db6945e]
/usr/lib/libc.so.6(+0x37e00)[0x7f3d4d6f7e00]
/usr/lib/libc.so.6(gsignal+0x10f)[0x7f3d4d6f7d7f]
/usr/lib/libc.so.6(abort+0x125)[0x7f3d4d6e2672]
/usr/lib/libc.so.6(+0x22548)[0x7f3d4d6e2548]
/usr/lib/libc.so.6(+0x30396)[0x7f3d4d6f0396]
/usr/lib/libchewing.so.3(+0x1179e)[0x7f3d46e0779e]
/usr/lib/libchewing.so.3(+0xcca9)[0x7f3d46e02ca9]
/usr/lib/libchewing.so.3(chewing_handle_Default+0x560)[0x7f3d46dffc20]
/usr/lib/fcitx/fcitx-chewing.so(+0x2729)[0x7f3d46e3d729]
/usr/lib/libfcitx-core.so.0(FcitxInstanceProcessKey+0x61a)[0x7f3d4dce85ea]
/usr/lib/fcitx/fcitx-ipc.so(+0x5aa3)[0x7f3d46330aa3]
/usr/lib/libdbus-1.so.3(+0x2673e)[0x7f3d4d11773e]
/usr/lib/libdbus-1.so.3(dbus_connection_dispatch+0x34d)[0x7f3d4d107dfd]
/usr/lib/fcitx/fcitx-dbus.so(+0x1ea9)[0x7f3d4d162ea9]
/usr/lib/fcitx/fcitx-dbus.so(+0x1fd9)[0x7f3d4d162fd9]
/usr/lib/libfcitx-core.so.0(+0x951c)[0x7f3d4dcdb51c]
/usr/lib/libfcitx-core.so.0(FcitxInstanceRun+0x330)[0x7f3d4dcdbfb0]
fcitx(+0xd8b)[0x55cc8db68d8b]
/usr/lib/libc.so.6(__libc_start_main+0xf3)[0x7f3d4d6e4223]
fcitx(+0xe0a)[0x55cc8db68e0a]

I will try to find time to study this issue.

yan12125 avatar Mar 25 '19 13:03 yan12125