From ddc8fcf66fd04dd3685a7788d62c2a00ce2a27ee Mon Sep 17 00:00:00 2001 From: Kunht Kun Date: Sat, 12 Mar 2022 00:04:10 -0500 Subject: Avoid dereferencing null pointer Here `comm` could be a null pointer (the new test regress/2057 shows such a case). So test it before dereferencing to avoid segfault. Re: #2057 --- test/regress/2057.test | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 test/regress/2057.test (limited to 'test') diff --git a/test/regress/2057.test b/test/regress/2057.test new file mode 100644 index 00000000..f691b350 --- /dev/null +++ b/test/regress/2057.test @@ -0,0 +1,12 @@ +C 1 "" = 1 $ + +2021-01-01 Test + A $10 + B + +test bal + 10 A + -10 B +-------------------- + 0 +end test -- cgit v1.2.3