[PATCH 13/14] Cleanup: bail on error

Dirk Hohndel dirk at hohndel.org
Thu Dec 28 16:35:41 PST 2017


Coverity CID 207809

Signed-off-by: Dirk Hohndel <dirk at hohndel.org>
---
 src/suunto_eonsteel.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/suunto_eonsteel.c b/src/suunto_eonsteel.c
index cddc8611abe8..78b91f7798d1 100644
--- a/src/suunto_eonsteel.c
+++ b/src/suunto_eonsteel.c
@@ -671,6 +671,7 @@ static int get_file_list(suunto_eonsteel_device_t *eon, struct directory_entry *
 		sizeof(result), result);
 	if (rc < 0) {
 		ERROR(eon->base.context, "cmd DIR_LOOKUP failed");
+		return -1;
 	}
 	HEXDUMP(eon->base.context, DC_LOGLEVEL_DEBUG, "DIR_LOOKUP", result, rc);
 
-- 
2.15.1



More information about the devel mailing list