Sanity check on order offset when hashing
This commit is contained in:
parent
f477c0fcc2
commit
1dc1218bfc
@ -133,6 +133,11 @@ library LibOrder {
|
||||
// ));
|
||||
|
||||
assembly {
|
||||
// Assert order offset (this is an internal error that should never be triggered)
|
||||
if lt(order, 32) {
|
||||
invalid()
|
||||
}
|
||||
|
||||
// Calculate memory addresses that will be swapped out before hashing
|
||||
let pos1 := sub(order, 32)
|
||||
let pos2 := add(order, 320)
|
||||
|
Loading…
x
Reference in New Issue
Block a user