Re: [PATCH v2 glib] gobject-stream: fix issue found by coverity

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 21.2.2014 12:24, Daniel P. Berrange wrote:
On Thu, Feb 20, 2014 at 04:58:21PM +0100, Pavel Hrdina wrote:
The coverity server found issue in gvir_stream_close function that
we ignore return values of g_input_stream_close and
g_output_stream_close, but we also ignore the error message and we
assume that it's closed without error.

Now we will check return values and also propagate the error message
to the upper layers. We should try to close both streams even if
closing the first one will fails. We can propagate only one error
message.

Signed-off-by: Pavel Hrdina <phrdina@xxxxxxxxxx>
---
  libvirt-gobject/libvirt-gobject-stream.c | 22 ++++++++++++++++++----
  1 file changed, 18 insertions(+), 4 deletions(-)

ACK

Regards,
Daniel
--
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|


Thanks, pushed.

Pavel

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]