Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
View | Details | Raw Unified | Return to bug 460244 | Differences between
and this patch

Collapse All | Expand All

(-)a/block.c (-1 / +6 lines)
Lines 683-688 static int bdrv_open_common(BlockDriverS Link Here
683
    if (drv->bdrv_file_open) {
683
    if (drv->bdrv_file_open) {
684
        if (file != NULL) {
684
        if (file != NULL) {
685
            bdrv_swap(file, bs);
685
            bdrv_swap(file, bs);
686
            if (bs->file != file) {
687
                g_free(file->opaque);
688
                file->opaque = NULL;
689
            }
686
            ret = 0;
690
            ret = 0;
687
        } else {
691
        } else {
688
            ret = drv->bdrv_file_open(bs, filename, open_flags);
692
            ret = drv->bdrv_file_open(bs, filename, open_flags);
Lines 1380-1386 void bdrv_delete(BlockDriverState *bs) Link Here
1380
    /* remove from list, if necessary */
1384
    /* remove from list, if necessary */
1381
    bdrv_make_anon(bs);
1385
    bdrv_make_anon(bs);
1382
1386
1383
    bdrv_close(bs);
1387
    if (bs->opaque)
1388
        bdrv_close(bs);
1384
1389
1385
    assert(bs != bs_snapshots);
1390
    assert(bs != bs_snapshots);
1386
    g_free(bs);
1391
    g_free(bs);

Return to bug 460244