From: Hsiangkai Wang Date: Wed, 1 May 2013 02:23:38 +0000 (+0800) Subject: gdb_server: remove target_handle_event from gdb event callback X-Git-Tag: v0.8.0-rc1~434 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=7eb0e3105908dae36841daf1dca0b1a4be50e4d3;p=openocd gdb_server: remove target_handle_event from gdb event callback In target_call_event_callbacks(), it will execute 1. target_handle_event (use Jim_EvalObj() to evaluate event statements in config files) 2. call user registered callbacks Before calling user registered callbacks, target_handle_event has been executed. So, there is no need to call target_handle_event() in gdb event callback. It will execute event statements in config files twice. Change-Id: I84629e324fa3eb909907badf2319b4138ba89f07 Signed-off-by: Hsiangkai Wang Reviewed-on: http://openocd.zylin.com/1372 Tested-by: jenkins Reviewed-by: Spencer Oliver Reviewed-by: Freddie Chopin --- diff --git a/src/server/gdb_server.c b/src/server/gdb_server.c index e7f54281..cd726580 100644 --- a/src/server/gdb_server.c +++ b/src/server/gdb_server.c @@ -719,7 +719,6 @@ static int gdb_target_callback_event_handler(struct target *target, int retval; struct connection *connection = priv; - target_handle_event(target, event); switch (event) { case TARGET_EVENT_GDB_HALT: gdb_frontend_halted(target, connection);