[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH] block: Fix direct use of protocols as driver fo
From: |
Kevin Wolf |
Subject: |
Re: [Qemu-devel] [PATCH] block: Fix direct use of protocols as driver for bdrv_open() |
Date: |
Thu, 28 Mar 2013 12:13:40 +0100 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
Am 28.03.2013 um 11:53 hat Stefan Hajnoczi geschrieben:
> On Wed, Mar 27, 2013 at 05:28:18PM +0100, Kevin Wolf wrote:
> > bdrv_open_common() implements direct use of protocols by copying the
> > pre-opened BlockDriverStates to bs using bdrv_swap(). It did however
> > first set some fields in bs, which end up in file after the swap. When
> > bdrv_open() destroys file, it appears to be open, and because it isn't,
> > qemu could segfault while trying to close it.
> >
> > Reorder the operations to return immediately in such cases so that file
> > is correctly detected as closed.
> >
> > Signed-off-by: Kevin Wolf <address@hidden>
> > ---
> > block.c | 31 +++++++++++++++----------------
> > 1 file changed, 15 insertions(+), 16 deletions(-)
>
> Didn't apply cleanly, please check that I resolved the conflict
> correctly.
Sorry, my bad, this was accidentally on top of a temporary quick fix...
You conflict resolution is correct.
Kevin