This is an automated email from Gerrit.

"Toms Stūrmanis <toms.sturma...@gmail.com>" just uploaded a new patch set to 
Gerrit, which you can find at https://review.openocd.org/c/openocd/+/7194

-- gerrit

commit 933df800ce8534e51547044636edf0c4f7dd1217
Author: Toms Stūrmanis <toms.sturma...@gmail.com>
Date:   Wed Sep 14 15:13:59 2022 +0300

    flash/nor/rsl10: Check return value
    
    Change-Id: Id1ad72e74d6a1bddc4dfe46dcf715ef74e19a27f
    Signed-off-by: Toms Stūrmanis <toms.sturma...@gmail.com>

diff --git a/src/flash/nor/rsl10.c b/src/flash/nor/rsl10.c
index 164701fe00..ef501f4ee1 100644
--- a/src/flash/nor/rsl10.c
+++ b/src/flash/nor/rsl10.c
@@ -747,6 +747,8 @@ COMMAND_HANDLER(rsl10_unlock_command)
 
        uint32_t key;
        retval = mem_ap_read_atomic_u32(ap, 
RSL10_FLASH_ADDRESS_LOCK_INFO_SETTING, &key);
+       if (retval != ERROR_OK)
+               return retval;
        LOG_INFO("mem read: 0x%08" PRIx32, key);
 
        if (key == RSL10_KEY_DEBUG_LOCK) {

-- 

Reply via email to