rtos: fix bug in error handling

checking for != ERROR_FAIL is broken.

Change-Id: Id7085afac653bb9c38d08928227a9ea402d8e6e9
Signed-off-by: Øyvind Harboe <oyvind.harboe@zylin.com>
Reviewed-on: http://openocd.zylin.com/351
Tested-by: jenkins
Reviewed-by: Michel JAOUEN <michel.jaouen@stericsson.com>
Reviewed-by: Øyvind Harboe <oyvindharboe@gmail.com>
__archive__
Øyvind Harboe 2012-01-07 09:55:54 +01:00 committed by Øyvind Harboe
parent e8b094b846
commit 3cbed17e18
1 changed files with 2 additions and 2 deletions

View File

@ -1039,8 +1039,8 @@ static int gdb_get_registers_packet(struct connection *connection,
LOG_DEBUG("-");
#endif
if ( ( target->rtos != NULL ) &&
( ERROR_FAIL != rtos_get_gdb_reg_list( connection, &reg_list, &reg_list_size) ) )
if ((target->rtos != NULL) &&
(ERROR_OK == rtos_get_gdb_reg_list(connection, &reg_list, &reg_list_size)))
{
return ERROR_OK;
}