From 9c06b227199db67c73e7f08573fc3f56878d8bdd Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Fri, 13 Mar 2020 01:59:35 +0900 Subject: [PATCH] [qfcc] Fix segfault when assigning {} --- tools/qfcc/source/expr_assign.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/qfcc/source/expr_assign.c b/tools/qfcc/source/expr_assign.c index f0dca6474..aa759b88d 100644 --- a/tools/qfcc/source/expr_assign.c +++ b/tools/qfcc/source/expr_assign.c @@ -322,7 +322,7 @@ assign_expr (expr_t *dst, expr_t *src) return expr; } } else { - if (!is_memset (src) && is_scalar (dst_type)) { + if (!src && is_scalar (dst_type)) { return error (dst, "empty scalar initializer"); } src = new_nil_expr ();