From: Øyvind H. <go...@us...> - 2009-12-01 07:53:39
|
This is an automated email from the git hooks/post-receive script. It was generated because a ref change was pushed to the repository containing the project "Main OpenOCD repository". The branch, master has been updated via 51e9b25c9ae3478989940f925a36d78364d88764 (commit) from 330733eadf76ea87ee8714ed7958f174b1be21db (commit) Those revisions listed above that are new to this repository have not appeared on any other notification email; so we list those revisions in full, below. - Log ----------------------------------------------------------------- commit 51e9b25c9ae3478989940f925a36d78364d88764 Author: Ãyvind Harboe <oyv...@zy...> Date: Mon Nov 30 09:13:56 2009 +0100 main: invoke jtag_interface_quit() explicitly There is no particular reason to invoke jtag_interface_quit() on the atexit() handler, it just makes the code more obtuse and stops other legitimate usage of atexit(). Signed-off-by: Ãyvind Harboe <oyv...@zy...> diff --git a/src/openocd.c b/src/openocd.c index 1be209a..22d4582 100644 --- a/src/openocd.c +++ b/src/openocd.c @@ -60,10 +60,6 @@ COMMAND_HANDLER(handle_version_command) return ERROR_OK; } -static void exit_handler(void) -{ - jtag_interface_quit(); -} static int log_target_callback_event_handler(struct target *target, enum target_event event, void *priv) { @@ -115,8 +111,6 @@ COMMAND_HANDLER(handle_init_command) initialized = 1; - atexit(exit_handler); - command_context_mode(CMD_CTX, COMMAND_EXEC); if (target_init(CMD_CTX) != ERROR_OK) @@ -303,5 +297,7 @@ int openocd_main(int argc, char *argv[]) /* free commandline interface */ command_done(cmd_ctx); + jtag_interface_quit(); + return ret; } ----------------------------------------------------------------------- Summary of changes: src/openocd.c | 8 ++------ 1 files changed, 2 insertions(+), 6 deletions(-) hooks/post-receive -- Main OpenOCD repository |