Skip to content

Commit

Permalink
Don't std::move dimensions when setting up a stream.
Browse files Browse the repository at this point in the history
  • Loading branch information
aliddell committed Sep 16, 2024
1 parent ee97d3e commit afa9ace
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
9 changes: 7 additions & 2 deletions include/zarr.types.h
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,9 @@ extern "C"
ZarrDimensionTypeCount
} ZarrDimensionType;

/**
* @brief S3 settings for streaming to Zarr.
*/
typedef struct
{
const char* endpoint;
Expand All @@ -107,11 +110,13 @@ extern "C"
uint8_t shuffle; /**< Whether to shuffle the data before compressing */
} ZarrCompressionSettings;

/**
* @brief Properties of a dimension of the Zarr array.
*/
typedef struct
{
const char* name; /**< Name of the dimension */
size_t
bytes_of_name; /**< Length of the name, including null terminator */
size_t bytes_of_name; /**< Bytes in @p name, including null terminator */
ZarrDimensionType kind; /**< Type of the dimension */
uint32_t array_size_px; /**< Size of the array along this dimension in
pixels */
Expand Down
2 changes: 0 additions & 2 deletions src/streaming/zarr.stream.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -418,8 +418,6 @@ ZarrStream::ZarrStream_s(struct ZarrStreamSettings_s* settings, uint8_t version)
, version_(version)
, error_()
{
settings_.dimensions = std::move(settings->dimensions);

// spin up thread pool
thread_pool_ = std::make_shared<zarr::ThreadPool>(
std::thread::hardware_concurrency(),
Expand Down

0 comments on commit afa9ace

Please sign in to comment.