From 2aaf6641a2d34571c2cceb6b5d6d382ac947d5df Mon Sep 17 00:00:00 2001 From: wangmingrong1 Date: Mon, 2 Dec 2024 09:39:03 +0800 Subject: [PATCH] Fix compile error 'ret' may be used uninitialized Signed-off-by: wangmingrong1 --- sched/misc/coredump.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sched/misc/coredump.c b/sched/misc/coredump.c index 9d00b080a3..e3c7e12e68 100644 --- a/sched/misc/coredump.c +++ b/sched/misc/coredump.c @@ -170,7 +170,7 @@ static int elf_emit_align(FAR struct elf_dumpinfo_s *cinfo) ELF_PAGESIZE) - cinfo->stream->nput; unsigned char null[256]; off_t total = align; - off_t ret; + off_t ret = 0; memset(null, 0, sizeof(null));