aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2021-01-01 23:15:51 +0100
committerLuc Van Oostenryck <luc.vanoostenryck@gmail.com>2021-01-02 09:51:27 +0100
commit4cad79e4450180e8568bb16d06b5d6806b2db35b (patch)
treea3cc747c56cdc8a7ae34f8a9e2032d7690cbd0ed
parentfe455dd6b9fb47743271f342691c4b68532f1260 (diff)
downloadsparse-4cad79e4450180e8568bb16d06b5d6806b2db35b.tar.gz
shut up a silly -Wmaybe-uninitialized warning
I understand why the compiler would complain about this 'maybe-uninitialized' variable (it's always initialized when used) but I don't understand why the warning suddenly occurs while the variable have already been dereferenced several times; But well ... Initialize it with NULL to shut up the warning. Signed-off-by: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
-rw-r--r--simplify.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/simplify.c b/simplify.c
index 12482d78..b0d2c1b5 100644
--- a/simplify.c
+++ b/simplify.c
@@ -1718,7 +1718,7 @@ static int simplify_compare(struct instruction *insn)
{
pseudo_t src1 = insn->src1;
pseudo_t src2 = insn->src2;
- struct instruction *def;
+ struct instruction *def = NULL;
unsigned int osize;
pseudo_t src;