MCPcopy
hub / github.com/awnumar/memguard / Next

Method Next

stream.go:129–134  ·  view source on GitHub ↗

Next grabs the next chunk of data from the Stream and returns it decrypted inside a LockedBuffer. Any error from the stream is forwarded.

()

Source from the content-addressed store, hash-verified

127
128// Next grabs the next chunk of data from the Stream and returns it decrypted inside a LockedBuffer. Any error from the stream is forwarded.
129func (s *Stream) Next() (*LockedBuffer, error) {
130 s.Lock()
131 defer s.Unlock()
132
133 return s.next()
134}
135
136// does not acquire mutex lock
137func (s *Stream) next() (*LockedBuffer, error) {

Callers 2

TestStreamNextFlushFunction · 0.95
SizeMethod · 0.80

Calls 1

nextMethod · 0.95

Tested by 1

TestStreamNextFlushFunction · 0.76