Skip to content

Commit

Permalink
Merge pull request #271 from kaidokert/main
Browse files Browse the repository at this point in the history
Fix a size_t/off_t mismatch build warning
  • Loading branch information
khaledhosny authored Dec 28, 2023
2 parents be94458 + 602d229 commit 22120ca
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 22120ca

Please sign in to comment.