The read-only changes broke qemu-img create with read-only base image These changes fix it. It also make things a little safer, opening the backing file for read-only, upgrading to read-write only for commit, and back to read-only when done.
Naphtali Sprei (4): Add open_flags to BlockDriverState Will be used later qemu-img: Fix qemu-img can't create qcow image based on read-only image Block: readonly changes Open backing file read-only also for snapshot mode block.c | 57 +++++++++++++++++++++++++++++++++++++++++++++++++-------- block_int.h | 2 ++ qemu-img.c | 15 ++++++++++----- 3 files changed, 61 insertions(+), 13 deletions(-)