[PATCH 0/3] tests: three easy Coverity fixes

Peter Maydell posted 3 patches 2 weeks ago
Test checkpatch passed
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20210503165525.26221-1-peter.maydell@linaro.org
Maintainers: Thomas Huth <thuth@redhat.com>, Paolo Bonzini <pbonzini@redhat.com>, Corey Minyard <minyard@acm.org>, Stefan Berger <stefanb@linux.vnet.ibm.com>, Laurent Vivier <lvivier@redhat.com>
tests/qtest/ipmi-bt-test.c  | 6 ++++--
tests/qtest/ipmi-kcs-test.c | 3 ++-
tests/qtest/rtc-test.c      | 6 ++----
tests/qtest/tpm-util.c      | 4 ++--
4 files changed, 10 insertions(+), 9 deletions(-)

[PATCH 0/3] tests: three easy Coverity fixes

Posted by Peter Maydell 2 weeks ago
We recently started running Coverity on our tests/ code,
which has revealed a pile of issues that we were previously
blissfully unaware of. This series fixes three easy ones:
 * use of free() where g_free() was meant
 * unnecessary NULL check
 * side effect inside g_assert() argument

thanks
-- PMM

Peter Maydell (3):
  tests/qtest/tpm-util.c: Free memory with correct free function
  tests/qtest/rtc-test: Remove pointless NULL check
  tests: Avoid side effects inside g_assert() arguments

 tests/qtest/ipmi-bt-test.c  | 6 ++++--
 tests/qtest/ipmi-kcs-test.c | 3 ++-
 tests/qtest/rtc-test.c      | 6 ++----
 tests/qtest/tpm-util.c      | 4 ++--
 4 files changed, 10 insertions(+), 9 deletions(-)

-- 
2.20.1