We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fe72cf4 commit c708c6dCopy full SHA for c708c6d
arrow/ipc/message.go
@@ -22,6 +22,7 @@ import (
22
"io"
23
"sync/atomic"
24
25
+ "github.com/apache/arrow-go/v18/arrow/internal/debug"
26
"github.com/apache/arrow-go/v18/arrow/internal/flatbuf"
27
"github.com/apache/arrow-go/v18/arrow/memory"
28
)
@@ -157,7 +158,7 @@ func (r *messageReader) Retain() {
157
158
// When the reference count goes to zero, the memory is freed.
159
// Release may be called simultaneously from multiple goroutines.
160
func (r *messageReader) Release() {
- r.refCount.Load()
161
+ debug.Assert(r.refCount.Load() > 0, "too many releases")
162
163
if r.refCount.Add(-1) == 0 {
164
if r.msg != nil {
0 commit comments