qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [PULL for-5.2 0/1] qemu-ga patch queue for hard-freeze
@ 2020-11-09 20:17 Michael Roth
  2020-11-09 20:17 ` [PULL for-5.2 1/1] qga: fix missing closedir() in qmp_guest_get_disks() Michael Roth
  2020-11-09 21:23 ` [PULL for-5.2 0/1] qemu-ga patch queue for hard-freeze Peter Maydell
  0 siblings, 2 replies; 5+ messages in thread
From: Michael Roth @ 2020-11-09 20:17 UTC (permalink / raw)
  To: qemu-devel; +Cc: peter.maydell

The following changes since commit 3493c36f0371777c62d1d72b205b0eb6117e2156:

  Merge remote-tracking branch 'remotes/cohuck/tags/s390x-20201106' into staging (2020-11-06 13:43:28 +0000)

are available in the Git repository at:

  git://github.com/mdroth/qemu.git tags/qga-pull-2020-11-09-tag

for you to fetch changes up to b1b9ab1c04d560f86d8da3dfca4d8b21de75fee6:

  qga: fix missing closedir() in qmp_guest_get_disks() (2020-11-09 14:07:14 -0600)

----------------------------------------------------------------
qemu-ga patch queue for hard-freeze

* fix leaked DIR* descriptor in guest-get-disks spotted by coverity

----------------------------------------------------------------
Michael Roth (1):
      qga: fix missing closedir() in qmp_guest_get_disks()

 qga/commands-posix.c | 3 +++
 1 file changed, 3 insertions(+)




^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PULL for-5.2 1/1] qga: fix missing closedir() in qmp_guest_get_disks()
  2020-11-09 20:17 [PULL for-5.2 0/1] qemu-ga patch queue for hard-freeze Michael Roth
@ 2020-11-09 20:17 ` Michael Roth
  2020-11-09 21:23 ` [PULL for-5.2 0/1] qemu-ga patch queue for hard-freeze Peter Maydell
  1 sibling, 0 replies; 5+ messages in thread
From: Michael Roth @ 2020-11-09 20:17 UTC (permalink / raw)
  To: qemu-devel
  Cc: peter.maydell, Tomáš Golembiovský,
	Philippe Mathieu-Daudé, Marc-André Lureau

We opendir("/sys/block") at the beginning of the function, but we never
close it prior to returning.

Fixes: Coverity CID 1436130
Fixes: fed3956429d5 ("qga: add implementation of guest-get-disks for Linux")
Reported-by: Peter Maydell <peter.maydell@linaro.org>
Cc: Marc-André Lureau <marcandre.lureau@redhat.com>
Cc: Tomáš Golembiovský <tgolembi@redhat.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: Michael Roth <michael.roth@amd.com>
---
 qga/commands-posix.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/qga/commands-posix.c b/qga/commands-posix.c
index 3711080d07..12c1ba5ef7 100644
--- a/qga/commands-posix.c
+++ b/qga/commands-posix.c
@@ -1443,6 +1443,9 @@ GuestDiskInfoList *qmp_guest_get_disks(Error **errp)
         get_disk_deps(disk_dir, disk);
         ret = get_disk_partitions(ret, de->d_name, disk_dir, dev_name);
     }
+
+    closedir(dp);
+
     return ret;
 }
 
-- 
2.25.1



^ permalink raw reply related	[flat|nested] 5+ messages in thread

* Re: [PULL for-5.2 0/1] qemu-ga patch queue for hard-freeze
  2020-11-09 20:17 [PULL for-5.2 0/1] qemu-ga patch queue for hard-freeze Michael Roth
  2020-11-09 20:17 ` [PULL for-5.2 1/1] qga: fix missing closedir() in qmp_guest_get_disks() Michael Roth
@ 2020-11-09 21:23 ` Peter Maydell
  1 sibling, 0 replies; 5+ messages in thread
From: Peter Maydell @ 2020-11-09 21:23 UTC (permalink / raw)
  To: Michael Roth; +Cc: QEMU Developers

On Mon, 9 Nov 2020 at 20:18, Michael Roth <michael.roth@amd.com> wrote:
>
> The following changes since commit 3493c36f0371777c62d1d72b205b0eb6117e2156:
>
>   Merge remote-tracking branch 'remotes/cohuck/tags/s390x-20201106' into staging (2020-11-06 13:43:28 +0000)
>
> are available in the Git repository at:
>
>   git://github.com/mdroth/qemu.git tags/qga-pull-2020-11-09-tag
>
> for you to fetch changes up to b1b9ab1c04d560f86d8da3dfca4d8b21de75fee6:
>
>   qga: fix missing closedir() in qmp_guest_get_disks() (2020-11-09 14:07:14 -0600)
>
> ----------------------------------------------------------------
> qemu-ga patch queue for hard-freeze
>
> * fix leaked DIR* descriptor in guest-get-disks spotted by coverity
>
> ----------------------------------------------------------------

Applied, thanks.

Please update the changelog at https://wiki.qemu.org/ChangeLog/5.2
for any user-visible changes.

-- PMM


^ permalink raw reply	[flat|nested] 5+ messages in thread

* [PULL for-5.2 0/1] qemu-ga patch queue for hard-freeze
@ 2020-11-16 19:21 Michael Roth
  2020-11-16 22:26 ` Peter Maydell
  0 siblings, 1 reply; 5+ messages in thread
From: Michael Roth @ 2020-11-16 19:21 UTC (permalink / raw)
  To: qemu-devel; +Cc: peter.maydell

The following changes since commit 2f7c9dd5181524ceaf75ba3ef8d84090b1e9e8d8:

  Merge remote-tracking branch 'remotes/kraxel/tags/fixes-20201116-pull-request' into staging (2020-11-16 14:19:31 +0000)

are available in the Git repository at:

  git://github.com/mdroth/qemu.git tags/qga-pull-2020-11-16-tag

for you to fetch changes up to a8aa94b5f8427cc2924d8cdd417c8014db1c86c0:

  qga: update schema for guest-get-disks 'dependents' field (2020-11-16 10:48:11 -0600)

----------------------------------------------------------------
qemu-ga patch queue for hard-freeze

* fixes for schema data-type declarations for guest-get-disks

----------------------------------------------------------------
Michael Roth (1):
      qga: update schema for guest-get-disks 'dependents' field

 qga/commands-posix.c | 10 ++++++----
 qga/qapi-schema.json |  8 ++++----
 2 files changed, 10 insertions(+), 8 deletions(-)




^ permalink raw reply	[flat|nested] 5+ messages in thread

* Re: [PULL for-5.2 0/1] qemu-ga patch queue for hard-freeze
  2020-11-16 19:21 Michael Roth
@ 2020-11-16 22:26 ` Peter Maydell
  0 siblings, 0 replies; 5+ messages in thread
From: Peter Maydell @ 2020-11-16 22:26 UTC (permalink / raw)
  To: Michael Roth; +Cc: QEMU Developers

On Mon, 16 Nov 2020 at 19:22, Michael Roth <michael.roth@amd.com> wrote:
>
> The following changes since commit 2f7c9dd5181524ceaf75ba3ef8d84090b1e9e8d8:
>
>   Merge remote-tracking branch 'remotes/kraxel/tags/fixes-20201116-pull-request' into staging (2020-11-16 14:19:31 +0000)
>
> are available in the Git repository at:
>
>   git://github.com/mdroth/qemu.git tags/qga-pull-2020-11-16-tag
>
> for you to fetch changes up to a8aa94b5f8427cc2924d8cdd417c8014db1c86c0:
>
>   qga: update schema for guest-get-disks 'dependents' field (2020-11-16 10:48:11 -0600)
>
> ----------------------------------------------------------------
> qemu-ga patch queue for hard-freeze
>
> * fixes for schema data-type declarations for guest-get-disks
>
> ----------------------------------------------------------------


Applied, thanks.

Please update the changelog at https://wiki.qemu.org/ChangeLog/5.2
for any user-visible changes.

-- PMM


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2020-11-16 22:27 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-11-09 20:17 [PULL for-5.2 0/1] qemu-ga patch queue for hard-freeze Michael Roth
2020-11-09 20:17 ` [PULL for-5.2 1/1] qga: fix missing closedir() in qmp_guest_get_disks() Michael Roth
2020-11-09 21:23 ` [PULL for-5.2 0/1] qemu-ga patch queue for hard-freeze Peter Maydell
  -- strict thread matches above, loose matches on Subject: below --
2020-11-16 19:21 Michael Roth
2020-11-16 22:26 ` Peter Maydell

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).