|
From: OpenOCD-Gerrit <ope...@us...> - 2022-10-15 15:58:42
|
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 2d5d8a5a621811d0ea58d3bdb90afc17f0cce4ac (commit)
from 45c9e1e8c0809bc4305f269db239641151c6004d (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 2d5d8a5a621811d0ea58d3bdb90afc17f0cce4ac
Author: Erhan Kurubas <erh...@es...>
Date: Wed Oct 5 00:49:23 2022 +0200
target/esp32s2: check xtensa_poll return value
Although scan build couldn't catch, return value overwritten
without checking.
Signed-off-by: Erhan Kurubas <erh...@es...>
Change-Id: I02b10002b03640604315047e8a8a639824724c16
Reviewed-on: https://review.openocd.org/c/openocd/+/7247
Tested-by: jenkins
Reviewed-by: Ian Thompson <ia...@ca...>
Reviewed-by: Antonio Borneo <bor...@gm...>
diff --git a/src/target/espressif/esp32s2.c b/src/target/espressif/esp32s2.c
index 62d1ddb1d..64fa69057 100644
--- a/src/target/espressif/esp32s2.c
+++ b/src/target/espressif/esp32s2.c
@@ -402,6 +402,8 @@ static int esp32s2_poll(struct target *target)
{
enum target_state old_state = target->state;
int ret = esp_xtensa_poll(target);
+ if (ret != ERROR_OK)
+ return ret;
if (old_state != TARGET_HALTED && target->state == TARGET_HALTED) {
/* Call any event callbacks that are applicable */
-----------------------------------------------------------------------
Summary of changes:
src/target/espressif/esp32s2.c | 2 ++
1 file changed, 2 insertions(+)
hooks/post-receive
--
Main OpenOCD repository
|