blockdev.c (f2a1cf9180f63e88bb38ff21c169da97c3f2bad5) blockdev.c (e54ee1b385a9d084b4052b6db7391ea2fd799fa8)
1/*
2 * QEMU host block devices
3 *
4 * Copyright (c) 2003-2008 Fabrice Bellard
5 *
6 * This work is licensed under the terms of the GNU GPL, version 2 or
7 * later. See the COPYING file in the top-level directory.
8 *

--- 3402 unchanged lines hidden (view full) ---

3411
3412 if (ro) {
3413 if (bdrv_reopen_set_read_only(image_bs, false, errp) != 0) {
3414 goto out;
3415 }
3416 }
3417
3418 ret = bdrv_change_backing_file(image_bs, backing_file,
1/*
2 * QEMU host block devices
3 *
4 * Copyright (c) 2003-2008 Fabrice Bellard
5 *
6 * This work is licensed under the terms of the GNU GPL, version 2 or
7 * later. See the COPYING file in the top-level directory.
8 *

--- 3402 unchanged lines hidden (view full) ---

3411
3412 if (ro) {
3413 if (bdrv_reopen_set_read_only(image_bs, false, errp) != 0) {
3414 goto out;
3415 }
3416 }
3417
3418 ret = bdrv_change_backing_file(image_bs, backing_file,
3419 image_bs->drv ? image_bs->drv->format_name : "");
3419 image_bs->drv ? image_bs->drv->format_name : "",
3420 false);
3420
3421 if (ret < 0) {
3422 error_setg_errno(errp, -ret, "Could not change backing file to '%s'",
3423 backing_file);
3424 /* don't exit here, so we can try to restore open flags if
3425 * appropriate */
3426 }
3427

--- 317 unchanged lines hidden ---
3421
3422 if (ret < 0) {
3423 error_setg_errno(errp, -ret, "Could not change backing file to '%s'",
3424 backing_file);
3425 /* don't exit here, so we can try to restore open flags if
3426 * appropriate */
3427 }
3428

--- 317 unchanged lines hidden ---