vhdx-log.c (1c47613588ccff44422d4bdeea0dc36a0a308ec7) vhdx-log.c (307261b243df2edde538f3ed5c9d80e168529355)
1/*
2 * Block driver for Hyper-V VHDX Images
3 *
4 * Copyright (c) 2013 Red Hat, Inc.,
5 *
6 * Authors:
7 * Jeff Cody <jcody@redhat.com>
8 *

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

796 * sequence of valid entries present in the log. */
797
798 ret = vhdx_log_search(bs, s, &logs);
799 if (ret < 0) {
800 goto exit;
801 }
802
803 if (logs.valid) {
1/*
2 * Block driver for Hyper-V VHDX Images
3 *
4 * Copyright (c) 2013 Red Hat, Inc.,
5 *
6 * Authors:
7 * Jeff Cody <jcody@redhat.com>
8 *

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

796 * sequence of valid entries present in the log. */
797
798 ret = vhdx_log_search(bs, s, &logs);
799 if (ret < 0) {
800 goto exit;
801 }
802
803 if (logs.valid) {
804 if (bs->read_only) {
804 if (bdrv_is_read_only(bs)) {
805 bdrv_refresh_filename(bs);
806 ret = -EPERM;
807 error_setg(errp,
808 "VHDX image file '%s' opened read-only, but "
809 "contains a log that needs to be replayed",
810 bs->filename);
811 error_append_hint(errp, "To replay the log, run:\n"
812 "qemu-img check -r all '%s'\n",

--- 264 unchanged lines hidden ---
805 bdrv_refresh_filename(bs);
806 ret = -EPERM;
807 error_setg(errp,
808 "VHDX image file '%s' opened read-only, but "
809 "contains a log that needs to be replayed",
810 bs->filename);
811 error_append_hint(errp, "To replay the log, run:\n"
812 "qemu-img check -r all '%s'\n",

--- 264 unchanged lines hidden ---