coverity: Model g_poll()
PATCH v2 1/1 coverity: Model g_poll()
In my testing, Coverity reported two more CHECKED_RETURN:
* qemu-char.c:1248: fixed in commit c1f2448: "qemu-char: retry g_poll on EINTR".
* migration/qemu-file-unix.c:75: harmless, cleaned up in commit 4e39f57 "migration: Clean up use of g_poll() in socket_writev_buffer()
---
v2: Commit message body rewritten, because fixes have been committed meanwhile.
scripts/coverity-model.c | 9 +++++++++ 1 file changed, 9 insertions(+)
scripts/coverity-model.c +9 -0
@@ -342,6 +342,15 @@ char *g_strconcat(const char *s, ...)/* Other glib functions */ +typedef struct pollfd GPollFD ; + +int poll (); + +int g_poll (GPollFD *fds,unsigned nfds,int timeout) +{ +return poll (fds, nfds, timeout); +} +typedef struct _GIOChannel GIOChannel ;GIOChannel *g_io_channel_unix_new (int fd) {
Signature · 1 line
2.4.3
Paolo Bonzini
AppliedQuoted 5 lines · Markus Armbruster
In my testing, Coverity reported two more
CHECKED_RETURN:* qemu-char.c:1248: fixed in commit c1f2448: "qemu-char: retry
g_pollon EINTR".
Quoted 8 lines
*
migration/qemu-file-unix.c:75: harmless, cleaned up in commit 4e39f57 "migration: Clean up use ofg_poll()insocket_writev_buffer()Signed-off-by Markus Armbruster <[email protected]>---
v2: Commit message body rewritten, because fixes have been committed meanwhile.
Applied, thanks!
Paolo
Quoted 24 lines
scripts/coverity-model.c | 9 +++++++++ 1 file changed, 9 insertions(+)scripts/coverity-model.c +9
-0@@ -342,6 +342,15 @@ char *g_strconcat(const char *s, ...)/* Other glib functions */ +typedef struct pollfd GPollFD ; + +int poll (); + +int g_poll (GPollFD *fds,unsigned nfds,int timeout) +{ +return poll (fds, nfds, timeout); +} +typedef struct _GIOChannel GIOChannel ;GIOChannel *g_io_channel_unix_new (int fd) {
Quoted 10 lines · Paolo Bonzini
Quoted 9 lines · Markus Armbruster
In my testing, Coverity reported two more
CHECKED_RETURN:* qemu-char.c:1248: fixed in commit c1f2448: "qemu-char: retry
g_pollon EINTR".*
migration/qemu-file-unix.c:75: harmless, cleaned up in commit 4e39f57 "migration: Clean up use ofg_poll()insocket_writev_buffer()
Quoted 6 lines
Quoted 4 lines
Signed-off-by Markus Armbruster <[email protected]>---
v2: Commit message body rewritten, because fixes have been committed meanwhile.Applied, thanks!
There's also
Subject: [PATCH] coverity: Model g_memdup()
Date: Mon, 30 Nov 2015 17:32:32 +0100
Message-Id: <[email protected]>I can post a pull request for both, but I'm of course happy to let them flow through your tree.