Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
rbd: bench-write should return error if io-size >= 4G
Currently if user perform bench-write with io-size > 4G then its crashing because currently during memory allocation bufferptr taking size of buffer as a unsigned and io-size > 4G will overflow with unsigned. so during memset operation it will try to set io_size size of memory area pointed by bufferptr, (bufferptr area is: (4G - io_size)), so it will cause segmentation fault. Fix is to return error if io-size >= 4G Fixes: http://tracker.ceph.com/issues/18422 Reported-by: Jason Dillaman <dillaman@redhat.com> Signed-off-by: Gaurav Kumar Garg <garg.gaurav52@gmail.com>
- Loading branch information