-
Notifications
You must be signed in to change notification settings - Fork 277
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[fix] #1897: Removed usize/isize from serialization #1989
[fix] #1897: Removed usize/isize from serialization #1989
Conversation
Codecov Report
@@ Coverage Diff @@
## iroha2-dev #1989 +/- ##
==============================================
- Coverage 78.00% 77.76% -0.24%
==============================================
Files 176 174 -2
Lines 23951 23828 -123
==============================================
- Hits 18684 18531 -153
- Misses 5267 5297 +30
Continue to review full report at Codecov.
|
ea99006
to
ec59b12
Compare
b750861
to
2ec9034
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good job!
2ec9034
to
d249dd2
Compare
7df5d81
to
fd84821
Compare
Signed-off-by: Sam H. Smith <[email protected]>
Signed-off-by: Sam H. Smith <[email protected]>
7aa9552
to
788d8c3
Compare
Description of the Change
In all the locations where a struct derives Serialize or Deserialize usize has been replaced
with either u64 or u32. No instances of isize existed. In the cases where code using the
data required a usize u32 was chosen as the replacement. There is no point in avoiding usize
in the on disk formats if 32-bit platforms can't read and use the values written.
Issue
Resolves #1897
Benefits
No chance of crashing due to serializing on 64-bit then deserializing on 32-bit or vice versa.
Possible Drawbacks
This change limits the size of certain configuration values to 4 billion. Probably a non issue.