mirror of
https://github.com/kubeshark/kubeshark.git
synced 2025-06-24 23:34:45 +00:00
Bring back debug.FreeOSMemory()
call
This commit is contained in:
parent
0e88584227
commit
1cce863bbb
@ -2,6 +2,7 @@ package api
|
|||||||
|
|
||||||
import (
|
import (
|
||||||
"runtime"
|
"runtime"
|
||||||
|
"runtime/debug"
|
||||||
"sync"
|
"sync"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
@ -42,6 +43,7 @@ func (streamMap *TcpStreamMap) CloseTimedoutTcpStreamChannels() {
|
|||||||
for {
|
for {
|
||||||
<-ticker.C
|
<-ticker.C
|
||||||
|
|
||||||
|
debug.FreeOSMemory()
|
||||||
streamMap.Streams.Range(func(key interface{}, value interface{}) bool {
|
streamMap.Streams.Range(func(key interface{}, value interface{}) bool {
|
||||||
stream := value.(*TcpStream)
|
stream := value.(*TcpStream)
|
||||||
if stream.ProtoIdentifier.Protocol == nil {
|
if stream.ProtoIdentifier.Protocol == nil {
|
||||||
|
Loading…
Reference in New Issue
Block a user