From 43651d5172feaaa5b145d51947c3141b97e3b208 Mon Sep 17 00:00:00 2001 From: Ben Pfaff Date: Mon, 31 Aug 2020 10:29:52 -0700 Subject: [PATCH] value: Suppress uninitialized tmp.s warning in value_resize(). This warning is wrong, but it should not cause a performance problem to avoid it. Encountered with GCC 10.x. --- src/data/value.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/data/value.c b/src/data/value.c index bbe96b1980..55a1e55e85 100644 --- a/src/data/value.c +++ b/src/data/value.c @@ -161,7 +161,7 @@ void value_resize (union value *value, int old_width, int new_width) { assert (value_is_resizable (value, old_width, new_width)); - if (new_width != old_width) + if (new_width != old_width && new_width > 0) { union value tmp; value_init (&tmp, new_width); -- 2.30.2