-
Notifications
You must be signed in to change notification settings - Fork 36
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
NTFS fails on Ruby 2.4 #3
Comments
What exactly is the code in question doing? It looks like it interprets the 8 bytes as a 64-bit unsigned int, and then is (ab)using a Bignum check to verify that the value inside is not actually a 64-bit number but instead a different, smaller, number. I'd say that the code is probably checking for a 32-bit number but if so, then it's a bug, because the threshold for Fixnum/Bignum is not at the 32 bit boundary. For MRI (not even getting into that it's different on JRuby), it's actually at If the goal is to check for this actual threshold, then the code here might just want to compare the value to |
@Fryguy - I removed the offending check in: #10 I believe the check in question was added by the original author of the code, before it was stable. The only way the test could be true is if the data is corrupt. In all other cases, the code assumes the data it reads is valid and uses it. If it's not valid, it will fail down the line. There's no reason the same assumption shouldn't be made here. I also should add, we have never encountered the exception raised when the condition is true. So, I believe the test is useless. |
@chessbyte I think this can be closed by #10. We are running on ruby 2.4.1 on travis so, we're good to go here |
Oh @Fryguy beat me to it |
See https://travis-ci.org/ManageIQ/manageiq-smartstate/jobs/236485008 and ManageIQ/manageiq-gems-pending#101
The failure:
The text was updated successfully, but these errors were encountered: