Skip to content

Commit

Permalink
Correcting one buffer size selection
Browse files Browse the repository at this point in the history
  • Loading branch information
eddelbuettel committed Apr 2, 2024
1 parent d6efd8c commit ace4cc7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion libtiledbsoma/src/utils/arrow_adapter.cc
Original file line number Diff line number Diff line change
Expand Up @@ -445,7 +445,7 @@ ArrowAdapter::to_arrow(std::shared_ptr<ColumnBuffer> column) {
exitIfError(
ArrowArrayAllocateChildren(dict_arr, 0),
"Bad array children alloc");
const int n_buf = ArrowAdapter::_isstr(dict_sch->format) == 0 ? 3 : 2;
const int n_buf = ArrowAdapter::_isstr(dict_sch->format) == true ? 3 : 2;
dict_arr->buffers = (const void**)malloc(sizeof(void*) * n_buf);

Check warning on line 449 in libtiledbsoma/src/utils/arrow_adapter.cc

View check run for this annotation

Codecov / codecov/patch

libtiledbsoma/src/utils/arrow_adapter.cc#L443-L449

Added lines #L443 - L449 were not covered by tests
dict_arr->buffers[0] = nullptr; // validity: none here
dict_arr->release = &release_array;

Check warning on line 451 in libtiledbsoma/src/utils/arrow_adapter.cc

View check run for this annotation

Codecov / codecov/patch

libtiledbsoma/src/utils/arrow_adapter.cc#L451

Added line #L451 was not covered by tests
Expand Down

0 comments on commit ace4cc7

Please sign in to comment.