mirror of https://github.com/apache/cassandra
use long math for long values
This commit is contained in:
parent
7d36c1e025
commit
8bb5487eab
|
|
@ -115,7 +115,7 @@ public class SlabAllocator extends Allocator
|
||||||
*/
|
*/
|
||||||
public long getMinimumSize()
|
public long getMinimumSize()
|
||||||
{
|
{
|
||||||
return unslabbed.get() + (regionCount - 1) * REGION_SIZE;
|
return unslabbed.get() + (regionCount - 1) * (long)REGION_SIZE;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
@ -123,7 +123,7 @@ public class SlabAllocator extends Allocator
|
||||||
*/
|
*/
|
||||||
public long getMaximumSize()
|
public long getMaximumSize()
|
||||||
{
|
{
|
||||||
return unslabbed.get() + regionCount * REGION_SIZE;
|
return unslabbed.get() + regionCount * (long)REGION_SIZE;
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue