You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix: handle overflow when computing mmap offset during restore
Since we dropped the explicit offset field from the snapshot file, we
are implicit computing it as "sum of sizes of all preceding regions". If
the snapshot file is corrupted, it can describe regions whose sum
exceeds u64::MAX. Fix this by adding overflow checks and returning an
error in case of overflows
We also error out if it exceeds i64::MAX as the offset argument to
mmap(2) is a signed 64 bit integer value.
Fixes: d835805
Signed-off-by: Patrick Roy <[email protected]>
0 commit comments