Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion source/common/buffer/buffer_impl.cc
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,8 @@ RawSlice OwnedImpl::frontSlice() const {
// Ignore zero-size slices and return the first slice with data.
for (const auto& slice : slices_) {
if (slice.dataSize() > 0) {
return RawSlice{const_cast<uint8_t*>(slice.data()), slice.dataSize()};
return RawSlice{const_cast<uint8_t*>(slice.data()),
static_cast<absl::Span<uint8_t>::size_type>(slice.dataSize())};
}
}

Expand Down
2 changes: 1 addition & 1 deletion source/common/buffer/buffer_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ class SliceDataImpl : public SliceData {
// SliceData
absl::Span<uint8_t> getMutableData() override {
RELEASE_ASSERT(slice_.isMutable(), "Not allowed to call getMutableData if slice is immutable");
return {slice_.data(), slice_.dataSize()};
return {slice_.data(), static_cast<absl::Span<uint8_t>::size_type>(slice_.dataSize())};
}

private:
Expand Down