From: "Philippe Mathieu-Daudé" <f4bug@amsat.org>
To: "Peter Maydell" <peter.maydell@linaro.org>,
"Marc-André Lureau" <marcandre.lureau@redhat.com>,
"Paolo Bonzini" <pbonzini@redhat.com>,
"Eric Blake" <eblake@redhat.com>
Cc: "Philippe Mathieu-Daudé" <f4bug@amsat.org>,
qemu-devel@nongnu.org, qemu-trivial@nongnu.org
Subject: [Qemu-devel] [PATCH for 2.10 v2 00/20] fix bugs reported by Clang Static Analyzer
Date: Wed, 26 Jul 2017 23:42:05 -0300 [thread overview]
Message-ID: <20170727024224.22900-1-f4bug@amsat.org> (raw)
Hi,
This series is the result of [now NOT] having fun with Clang's Static Analyzer
(see https://clang-analyzer.llvm.org/).
v2:
- addressed review feedbacks,
- added various R-b,
- dropped noise (Peter sharp eye),
- dropped dup patches
Patches 1-13 are already reviewed,
Patches 14,15 address feedbacks from v1,
Patch 16 test if patch collecting tools can handle missing patches,
Patches 17-19 are new,
Patch 20 is new but not very important ;) bonus that can wait 2.11.
Regards,
Phil.
v1:
Patch 1 was in another series (delayed for 2.11), it would be nice to have it
in 2.10.
I ran Clang static analyzer "scan-build" via a docker image based on
debian/unstable to use bleeding code, if one is interested in reproduce or use
it the Dockerfile is available here:
http://lists.nongnu.org/archive/html/qemu-devel/2017-07/msg07487.html
I used the following commands:
$ ../configure --host-cc=clang-5.0 --cc=clang-5.0 --cxx=clang++-5.0 \
--disable-docs --enable-debug
$ scan-build-5.0 -o testresults --keep-going -maxloop 2 -no-failure-reports \
-analyzer-config stable-report-filename=true \
-disable-checker alpha.clone.CloneChecker \
-enable-checker alpha.core.CastSize \
-enable-checker alpha.core.Conversion \
-enable-checker alpha.core.IdenticalExpr \
-enable-checker alpha.core.SizeofPtr \
-disable-checker alpha.deadcode.UnreachableCode \
-enable-checker alpha.security.ArrayBoundV2 \
-enable-checker alpha.security.MallocOverflow \
-enable-checker alpha.unix.cstring.BufferOverlap \
-enable-checker alpha.unix.cstring.OutOfBounds \
-disable-checker deadcode.DeadStores \
-disable-checker optin.performance.Padding \
-enable-checker optin.portability.UnixAPI \
-disable-checker security.insecureAPI.getpw \
-disable-checker security.insecureAPI.gets \
-enable-checker security.insecureAPI.strcpy \
-disable-checker unix.Vfork \
make -k -j4
Philippe Mathieu-Daudé (20):
tests: add missing dependency to build QTEST_QEMU_BINARY
loader: check get_image_size() return value
ivshmem: fix incorrect error handling in ivshmem_recv_msg()
nbd: fix memory leak in nbd_opt_go()
qcow2: fix null pointer dereference
ui/vnc: fix leak of SocketAddress **
net/eth: fix incorrect check of iov_to_buf() return value
vfio/platform: fix use of freed memory
vfio/pci: fix use of freed memory
m68k/translate: fix incorrect copy/paste
linux-user/sh4: fix incorrect memory write
syscall: fix dereference of undefined pointer
syscall: fix use of uninitialized values
syscall: check inotify() and eventfd() return value
thunk: assert nb_fields is valid
bt-sdp: fix memory leak in sdp_service_record_build()
9pfs: avoid sign conversion error simplifying the code
spapr_vio: fix overflow of qdevs in spapr_dt_vdevice()
i2c/exynos4210: fix write to I2CADD register, bit 0 is not mapped
block/qcow2-refcount.c | 4 +--
hw/9pfs/9p.c | 6 ++---
hw/bt/sdp.c | 6 +++--
hw/core/loader.c | 4 +--
hw/i2c/exynos4210_i2c.c | 2 +-
hw/misc/ivshmem.c | 5 +++-
hw/ppc/spapr_vio.c | 4 +--
hw/vfio/pci.c | 11 ++++++---
hw/vfio/platform.c | 2 +-
linux-user/elfload.c | 2 +-
linux-user/syscall.c | 18 +++++++++++---
nbd/client.c | 8 +++---
net/eth.c | 4 +--
target/m68k/translate.c | 2 +-
tests/Makefile.include | 2 +-
thunk.c | 3 ++-
ui/vnc.c | 66 ++++++++++++++++++++++++-------------------------
17 files changed, 83 insertions(+), 66 deletions(-)
--
2.13.3
next reply other threads:[~2017-07-27 2:42 UTC|newest]
Thread overview: 32+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-27 2:42 Philippe Mathieu-Daudé [this message]
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 01/20] tests: add missing dependency to build QTEST_QEMU_BINARY Philippe Mathieu-Daudé
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 02/20] loader: check get_image_size() return value Philippe Mathieu-Daudé
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 03/20] ivshmem: fix incorrect error handling in ivshmem_recv_msg() Philippe Mathieu-Daudé
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 04/20] nbd: fix memory leak in nbd_opt_go() Philippe Mathieu-Daudé
2017-07-27 11:25 ` Eric Blake
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 05/20] qcow2: fix null pointer dereference Philippe Mathieu-Daudé
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 06/20] ui/vnc: fix leak of SocketAddress ** Philippe Mathieu-Daudé
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 07/20] net/eth: fix incorrect check of iov_to_buf() return value Philippe Mathieu-Daudé
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 08/20] vfio/platform: fix use of freed memory Philippe Mathieu-Daudé
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 09/20] vfio/pci: " Philippe Mathieu-Daudé
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 10/20] m68k/translate: fix incorrect copy/paste Philippe Mathieu-Daudé
2017-07-27 4:55 ` Richard Henderson
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 11/20] linux-user/sh4: fix incorrect memory write Philippe Mathieu-Daudé
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 12/20] syscall: fix dereference of undefined pointer Philippe Mathieu-Daudé
2017-07-27 6:39 ` Laurent Vivier
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 13/20] syscall: fix use of uninitialized values Philippe Mathieu-Daudé
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 14/20] syscall: check inotify() and eventfd() return value Philippe Mathieu-Daudé
2017-07-27 6:39 ` Laurent Vivier
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 15/20] thunk: assert nb_fields is valid Philippe Mathieu-Daudé
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 17/20] bt-sdp: fix memory leak in sdp_service_record_build() Philippe Mathieu-Daudé
2017-07-27 14:54 ` Paolo Bonzini
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 18/20] 9pfs: avoid sign conversion error simplifying the code Philippe Mathieu-Daudé
2017-07-27 11:40 ` Greg Kurz
2017-07-27 19:18 ` [Qemu-devel] [Qemu-trivial] " Philippe Mathieu-Daudé
2017-07-28 7:49 ` Greg Kurz
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 19/20] spapr_vio: fix overflow of qdevs in spapr_dt_vdevice() Philippe Mathieu-Daudé
2017-07-27 3:43 ` David Gibson
2017-07-27 4:35 ` Philippe Mathieu-Daudé
2017-07-27 2:42 ` [Qemu-devel] [PATCH for 2.10 v2 20/20] i2c/exynos4210: fix write to I2CADD register, bit 0 is not mapped Philippe Mathieu-Daudé
2017-07-28 11:44 ` Michael Tokarev
2017-07-28 11:45 ` [Qemu-devel] [PATCH for 2.10 v2 00/20] fix bugs reported by Clang Static Analyzer Michael Tokarev
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20170727024224.22900-1-f4bug@amsat.org \
--to=f4bug@amsat.org \
--cc=eblake@redhat.com \
--cc=marcandre.lureau@redhat.com \
--cc=pbonzini@redhat.com \
--cc=peter.maydell@linaro.org \
--cc=qemu-devel@nongnu.org \
--cc=qemu-trivial@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).