Re: [PATCH v2 2/3] virfile: Report error in virFileWrapperFdFree()

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

 



On Tue, 2019-02-19 at 15:49 +0000, Daniel P. Berrangé wrote:
> On Tue, Feb 19, 2019 at 04:42:51PM +0100, Andrea Bolognani wrote:
> > On Tue, 2019-02-19 at 13:58 +0000, Daniel P. Berrangé wrote:
> > > IOW, if we need to report an error from the io helper, then it
> > > needs to be done earlier, pehrpas in virFileWrapperFdClose ?
> > 
> > As John noted, that's what the original implementation looked like
> > but commit b0c3e931 moved the VIR_WARN() call from Close() to Free()
> > to avoid the situation where jumping out from a function early
> > results in the former not being called.
> 
> I think we should really just revert that commit and make sure
> the callers will invoke Close() in all paths & then make Close
> use virReportError instead of WARN.

Yeah, that's basically what I'm gonna try to do in v3 :)

-- 
Andrea Bolognani / Red Hat / Virtualization


[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]

  Powered by Linux