Skip to content

Commit ec70b67

Browse files
committed
Discard any auxiliary data in non-CoordBBox variant of readBuffers()
Signed-off-by: Dan Bailey <danbailey@ilm.com>
1 parent 7f4a717 commit ec70b67

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

openvdb/openvdb/tools/PointIndexGrid.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1732,6 +1732,11 @@ PointIndexLeafNode<T, Log2Dim>::readBuffers(std::istream& is, bool fromHalf)
17321732
// Reserved for future use
17331733
Index64 auxDataBytes = Index64(0);
17341734
is.read(reinterpret_cast<char*>(&auxDataBytes), sizeof(Index64));
1735+
if (auxDataBytes > 0) {
1736+
// For now, read and discard any auxiliary data.
1737+
std::unique_ptr<char[]> auxData{new char[auxDataBytes]};
1738+
is.read(auxData.get(), auxDataBytes);
1739+
}
17351740
}
17361741

17371742

0 commit comments

Comments
 (0)