Skip to content

Commit 75c9827

Browse files
Alex-PLACETCopilot
andcommitted
Update include/sparrow_ipc/serializer.hpp
Co-authored-by: Copilot <[email protected]>
1 parent 458a9cf commit 75c9827

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

include/sparrow_ipc/serializer.hpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,10 @@ namespace sparrow_ipc
109109
m_pstream->reserve(reserve_function);
110110
for (const auto& rb : record_batches)
111111
{
112+
if (get_column_dtypes(rb) != m_dtypes)
113+
{
114+
throw std::invalid_argument("Record batch schema does not match serializer schema");
115+
}
112116
serialize_record_batch(rb, *m_pstream);
113117
}
114118
}

0 commit comments

Comments
 (0)