mirror of
https://github.com/logos-storage/logos-storage-nim.git
synced 2026-05-12 22:39:26 +00:00
Signed-off-by: Arnaud <arno.deville@gmail.com> Co-authored-by: Eric <5089238+emizzle@users.noreply.github.com>
14 lines
439 B
Nim
14 lines
439 B
Nim
import pkg/storage/streams/storestream
|
|
import pkg/unittest2
|
|
|
|
const trackerNames = [StoreStreamTrackerName]
|
|
|
|
proc checkTrackers*() =
|
|
for name in trackerNames:
|
|
let counter = getTrackerCounter(name)
|
|
if counter.opened != counter.closed:
|
|
# show how many streams were opened vs closed to help diagnose the leak
|
|
checkpoint name & ": opened=" & $counter.opened & ", closed=" & $counter.closed
|
|
fail()
|
|
GC_fullCollect()
|