Re: [PATCH] qcow2-bitmap: Fix uint64_t left-shift overflow

2019-10-26 Thread Vladimir Sementsov-Ogievskiy
26.10.2019 12:19, Tuguoyi wrote: > In check_constraints_on_bitmap(), the sanity check on the > granularity will cause uint64_t integer left-shift overflow > when cluster_size is 2M and the granularity is bigger than > 32K which is even smaller than the default value for a qcow2 > disk with cluster_

[PATCH] qcow2-bitmap: Fix uint64_t left-shift overflow

2019-10-26 Thread Tuguoyi
In check_constraints_on_bitmap(), the sanity check on the granularity will cause uint64_t integer left-shift overflow when cluster_size is 2M and the granularity is bigger than 32K which is even smaller than the default value for a qcow2 disk with cluster_size set to 64k or bigger. This patch fix t