From 340ba3f84e88df567396e3ab9d6d2ae10d259729 Mon Sep 17 00:00:00 2001 From: temi54c1l8 Date: Wed, 26 Jun 2024 16:25:01 +0200 Subject: [PATCH] CO_SDOclient: static analysis: departure from MISRA switch syntax: missing break or throw from switch-case [MISRA 2012 Rule 16.1, required] --- 301/CO_SDOclient.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/301/CO_SDOclient.c b/301/CO_SDOclient.c index 649a2df..b8691bf 100644 --- a/301/CO_SDOclient.c +++ b/301/CO_SDOclient.c @@ -189,6 +189,7 @@ static ODR_t OD_write_1280(OD_stream_t *stream, const void *buf, switch (stream->subIndex) { case 0: /* Highest sub-index supported */ return ODR_READONLY; + break; case 1: { /* COB-ID client -> server */ uint32_t COB_ID = CO_getUint32(buf); @@ -241,6 +242,7 @@ static ODR_t OD_write_1280(OD_stream_t *stream, const void *buf, default: return ODR_SUB_NOT_EXIST; + break; } /* write value to the original location in the Object Dictionary */