From 0fe89f8cd09e37ccc8abcec334729888d6367253 Mon Sep 17 00:00:00 2001 From: Christopher Haster Date: Fri, 25 Apr 2025 15:03:25 -0500 Subject: [PATCH] Terminate all switch cases with at least LFS_UNREACHABLE() Just to be extra safe. No code changes. --- lfs.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lfs.c b/lfs.c index ce5db3dc..71f762c6 100644 --- a/lfs.c +++ b/lfs.c @@ -9530,6 +9530,7 @@ static int lfsr_mtree_traverse_(lfs_t *lfs, lfsr_traversal_t *t, LFS_ERROR("Weird mroot entry? 0x%"PRIx32, tag); return LFS_ERR_CORRUPT; } + LFS_UNREACHABLE(); // iterate over mdirs in the mtree case LFSR_TSTATE_MDIRS:; @@ -9617,6 +9618,7 @@ static int lfsr_mtree_traverse_(lfs_t *lfs, lfsr_traversal_t *t, LFSR_TSTATE_OMDIRS); continue; } + LFS_UNREACHABLE(); // scan for blocks/btrees in our opened file list case LFSR_TSTATE_OMDIRS:;