Files
sw_openocd/src/target
Tomas Vanek d7558e2ed6 target/armv7m: fix static analyzer warning
Despite of assert(is_packed) clang static analyser complains on use
of the uninitialized offset variable.

Cross compiling with latest x86_64-w64-mingw32-gcc hits warnings
	src/target/armv7m.c: In function ‘armv7m_read_core_reg’:
	src/target/armv7m.c:337:54: error: ‘reg32_id’ may be used
	    uninitialized in this function [-Werror=maybe-uninitialized]

It happens because mingw32 defines assert() without the attribute
"noreturn", whatever NDEBUG is defined or not.

Replace assert(is_packed) by if (is_packed) conditional and call
assert(false) in the else branch.

Change-Id: Id3c7dcccb65106e28be200b9a4d2b642f4d31019
Signed-off-by: Tomas Vanek <vanekt@fbl.cz>
Reviewed-on: http://openocd.zylin.com/6256
Tested-by: jenkins
Reviewed-by: Antonio Borneo <borneo.antonio@gmail.com>
Reviewed-by: Tarek BOCHKATI <tarek.bouchkati@gmail.com>
Reviewed-by: Andrzej Sierżęga <asier70@gmail.com>
2021-05-18 09:03:28 +01:00
..
2021-03-10 21:34:13 +00:00
2021-05-01 14:35:09 +01:00
2016-05-24 22:30:55 +01:00
2021-03-19 22:00:34 +00:00
2018-04-10 09:13:02 +01:00
2020-07-08 22:07:38 +01:00
2020-07-08 22:07:38 +01:00
2021-05-01 14:35:09 +01:00
2020-03-12 10:11:19 +00:00
2016-05-24 22:30:55 +01:00
2021-05-01 14:35:09 +01:00
2020-07-08 22:08:08 +01:00
2018-12-12 08:47:44 +00:00
2018-12-12 08:47:44 +00:00
2018-12-12 08:47:44 +00:00
2016-05-24 22:30:55 +01:00
2021-05-01 14:35:09 +01:00
2021-04-11 21:34:30 +01:00
2019-11-28 16:59:15 +00:00
2020-07-08 22:08:08 +01:00
2019-11-28 16:59:15 +00:00
2017-05-08 18:04:56 +01:00
2021-05-01 14:35:09 +01:00
2020-10-30 22:00:49 +00:00
2020-02-15 15:36:56 +00:00
2021-05-01 14:35:09 +01:00
2020-12-02 23:15:52 +00:00
2020-12-02 23:15:52 +00:00
2021-05-01 14:35:09 +01:00
2021-05-01 14:35:09 +01:00
2016-05-24 22:30:55 +01:00