ZTS: fix reservation_013_pos integer overflow
When using large disks the integers for calculating sizes can overflow past 2**31. Changing to long integers with typeset should correct this. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Signed-off-by: bunder2015 <omfgbunder@gmail.com> Closes #4444 Closes #7451
This commit is contained in:
parent
7f96cc23ac
commit
b40d45bc6c
|
@ -75,9 +75,9 @@ space_avail=$(get_prop available $TESTPOOL)
|
|||
[[ $? -ne 0 ]] && \
|
||||
log_fail "Unable to get space available property for $TESTPOOL"
|
||||
|
||||
((resv_set = space_avail / 5))
|
||||
typeset -il resv_set=space_avail/5
|
||||
resv_set=$(floor_volsize $resv_set)
|
||||
((sparse_vol_set_size = space_avail * 5))
|
||||
typeset -il sparse_vol_set_size=space_avail*5
|
||||
sparse_vol_set_size=$(floor_volsize $sparse_vol_set_size)
|
||||
|
||||
# When initially created, a regular volume's reservation property is set
|
||||
|
|
Loading…
Reference in New Issue