Skip to content

Commit

Permalink
fix: Revert reuse deserialize result to fix data overwritten
Browse files Browse the repository at this point in the history
See also milvus-io#34637

Signed-off-by: Congqi Xia <[email protected]>
  • Loading branch information
congqixia committed Jul 15, 2024
1 parent 48898ce commit a442fc4
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions internal/storage/serde.go
Original file line number Diff line number Diff line change
Expand Up @@ -538,9 +538,8 @@ func (deser *DeserializeReader[T]) Next() error {
deser.pos = 0
deser.rec = deser.rr.Record()

if deser.values == nil || len(deser.values) != deser.rec.Len() {
deser.values = make([]T, deser.rec.Len())
}

if err := deser.deserializer(deser.rec, deser.values); err != nil {
return err
}
Expand Down

0 comments on commit a442fc4

Please sign in to comment.