diff options
Diffstat (limited to 'block-qcow2.c')
-rw-r--r-- | block-qcow2.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/block-qcow2.c b/block-qcow2.c index 2df0615440..fca1d03c46 100644 --- a/block-qcow2.c +++ b/block-qcow2.c @@ -1076,7 +1076,7 @@ static int qcow_create(const char *filename, int64_t total_size, s->cluster_size = 1 << s->cluster_bits; header.cluster_bits = cpu_to_be32(s->cluster_bits); header_size = (header_size + 7) & ~7; - if (flags) { + if (flags & BLOCK_FLAG_ENCRYPT) { header.crypt_method = cpu_to_be32(QCOW_CRYPT_AES); } else { header.crypt_method = cpu_to_be32(QCOW_CRYPT_NONE); |