Skip to content
Snippets Groups Projects
Unverified Commit 9e1f89ef authored by eugene7646's avatar eugene7646 Committed by GitHub
Browse files

Merge pull request #2745 from gdicristofaro/8413-linuxBuildFixes

8413 fix for signedness
parents fce5d5e9 c0075fd5
No related branches found
No related tags found
No related merge requests found
...@@ -456,11 +456,11 @@ class APFSBtreeNode : public APFSObject, public APFSOmap::node_tag { ...@@ -456,11 +456,11 @@ class APFSBtreeNode : public APFSObject, public APFSOmap::node_tag {
throw std::runtime_error("APFSBtreeNode: invalid toffset"); throw std::runtime_error("APFSBtreeNode: invalid toffset");
} }
_table_data.voff = _storage.data() + voffset(); _table_data.voff = _storage.data() + voffset();
if (_table_data.voff - _storage.data() > _storage.size()) { if (_table_data.voff > _storage.data() + _storage.size()) {
throw std::runtime_error("APFSBtreeNode: invalid voffset"); throw std::runtime_error("APFSBtreeNode: invalid voffset");
} }
_table_data.koff = _storage.data() + koffset(); _table_data.koff = _storage.data() + koffset();
if (_table_data.koff - _storage.data() > _storage.size()) { if (_table_data.koff > _storage.data() + _storage.size()) {
throw std::runtime_error("APFSBtreeNode: invalid koffset"); throw std::runtime_error("APFSBtreeNode: invalid koffset");
} }
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment