mirror of
https://github.com/seaweedfs/seaweedfs.git
synced 2026-09-16 19:40:43 +02:00
revert slat clearing
This commit is contained in:
@@ -42,9 +42,6 @@ func getSlotPool(size int) (*sync.Pool, bool) {
|
||||
func Allocate(size int) []byte {
|
||||
if pool, found := getSlotPool(size); found {
|
||||
slab := *pool.Get().(*[]byte)
|
||||
for i, _ := range slab {
|
||||
slab[i] = 0
|
||||
}
|
||||
return slab[:size]
|
||||
}
|
||||
return make([]byte, size)
|
||||
|
||||
Reference in New Issue
Block a user