-
-
Notifications
You must be signed in to change notification settings - Fork 28
Open
Description
Invalid memory access (signal 11) at address 0x0
[0x55eb4f123e66] *Exception::CallStack::print_backtrace:Nil +118 in bin/translater
[0x55eb4f1048e6] ~procProc(Int32, Pointer(LibC::SiginfoT), Pointer(Void), Nil) +310 in bin/translater
[0x7f828811c770] ?? +140198605342576 in /usr/lib/libc.so.6
[0x0] ???
I can reproduce this on my recent version translater.
it is an simple app with infrequent access to SQL.
reproduce
- clone https://github.com/crystal-china/translater and switch to sqlite3_exception branch.
- shards install
- shards build
- run
bin/translater -e baidu,bing 'hello world'
As you can see, it raise Invalid memory access this time, but it work on next time.
the broken code is here, when insert into two table in same db file in a times loop.
Anyway, i thiought whatever happen don't should cause a Invalid memory access.
Add a sleep 0.1 after this line, seem like fix this issue.
BTW: same issue happen both on use DB.connect or DB.open.
Test on Crystal 1.12.0
Thanks
Metadata
Metadata
Assignees
Labels
No labels
