aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--fmap.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/fmap.c b/fmap.c
index 84b3b549..31f282fd 100644
--- a/fmap.c
+++ b/fmap.c
@@ -132,9 +132,8 @@ int fmap_read_from_buffer(struct fmap **fmap_out, const uint8_t *const buf, size
if (offset < 0) {
msg_gdbg("Unable to find fmap in provided buffer.\n");
return 2;
- } else {
- msg_gdbg("Found fmap at offset 0x%06zx\n", (size_t)offset);
}
+ msg_gdbg("Found fmap at offset 0x%06zx\n", (size_t)offset);
const struct fmap *fmap = (const struct fmap *)(buf + offset);
*fmap_out = malloc(fmap_size(fmap));
@@ -251,10 +250,9 @@ static int fmap_bsearch_rom(struct fmap **fmap_out, struct flashctx *const flash
msg_gdbg("fmap found at offset 0x%06zx\n", offset);
fmap_found = 1;
break;
- } else {
- msg_gerr("fmap signature found at %zu but header is invalid.\n", offset);
- ret = 2;
}
+ msg_gerr("fmap signature found at %zu but header is invalid.\n", offset);
+ ret = 2;
}
if (fmap_found)