Skip to content

Commit

Permalink
Fix a size_t/off_t mismatch build warning.
Browse files Browse the repository at this point in the history
  • Loading branch information
kaidokert committed Dec 27, 2023
1 parent be94458 commit 602d229
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions include/ots-memory-stream.h
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ class MemoryStream : public OTSStream {
return false;
}
std::memcpy(static_cast<char*>(ptr_) + off_, data, length);
off_ += length;
off_ += static_cast<off_t>(length);
return true;
}

Expand Down Expand Up @@ -82,7 +82,7 @@ class ExpandingMemoryStream : public OTSStream {
return WriteRaw(data, length);
}
std::memcpy(static_cast<char*>(ptr_) + off_, data, length);
off_ += length;
off_ += static_cast<off_t>(length);
return true;
}

Expand Down

0 comments on commit 602d229

Please sign in to comment.