sysbench crash at script_lua.c:860

Bug #1403699 reported by july
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
sysbench
Status tracked in Trunk
Trunk
Fix Committed
Undecided
Alexey Kopytov

Bug Description

1. Sysbench crashed when executing a lua script which without 'END' used right.

2. Crash information is as bellow.
(gdb) bt
#0 sb_lua_db_execute (L=0x23317f0) at script_lua.c:860
#1 0x00000000004198c4 in luaD_precall (L=0x23317f0, func=<value optimized out>, nresults=<value optimized out>) at ldo.c:319
#2 0x0000000000428db9 in luaV_execute (L=<value optimized out>, nexeccalls=1) at lvm.c:587
#3 0x000000000041a32d in luaD_call (L=0x23317f0, func=0x2331bf0, nResults=<value optimized out>) at ldo.c:377
#4 0x0000000000419327 in luaD_rawrunprotected (L=0x23317f0, f=0x416770 <f_call>, ud=0x7fff13dcbd80) at ldo.c:116
#5 0x00000000004193a2 in luaD_pcall (L=0x23317f0, func=<value optimized out>, u=<value optimized out>, old_top=64, ef=<value optimized out>) at ldo.c:461
#6 0x00000000004163df in lua_pcall (L=0x23317f0, nargs=0, nresults=0, errfunc=<value optimized out>) at lapi.c:817
#7 0x000000000041221d in sb_lua_new_state (scriptname=0x2330750 "./tests/db/ob_oltp_ps.lua", thread_id=-1) at script_lua.c:479
#8 0x000000000041228a in script_load_lua (testname=0x2330750 "./tests/db/ob_oltp_ps.lua", test=0x89a140) at script_lua.c:172
#9 0x00000000004118bd in script_load (testname=0x2330750 "./tests/db/ob_oltp_ps.lua") at sb_script.c:37
#10 0x0000000000407ad8 in main (argc=<value optimized out>, argv=<value optimized out>) at sysbench.c:1152

3. Example test file like this:

pathtest = string.match(test, "(.*/)") or ""

dofile(pathtest .. "ob_common.lua")

function thread_init(thread_id)
   set_vars()
end

function event(thread_id)
   end
   if not oltp_skip_trx then
      db_query("begin")
   end

july (zsr20042646)
description: updated
description: updated
july (zsr20042646)
description: updated
Revision history for this message
Alexey Kopytov (akopytov) wrote :

Thank you for the bug report. Fixed in trunk.

Revision history for this message
XCheng (csforgood) wrote :

good!

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.