We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent cb77273 commit 324bb4cCopy full SHA for 324bb4c
Sources/Fuzzilli/Base/ProgramBuilder.swift
@@ -3877,12 +3877,7 @@ public class ProgramBuilder {
3877
// Generate an in-bounds offset (dynamicOffset + staticOffset) into the memory.
3878
let dynamicOffsetValue = self.randomNonNegativeIndex(upTo: memSize)
3879
let dynamicOffset = function.memoryArgument(dynamicOffsetValue, memoryTypeInfo)
3880
- var staticOffset: Int64
3881
- if (dynamicOffsetValue == memSize) {
3882
- staticOffset = 0
3883
- } else {
3884
- staticOffset = self.randomNonNegativeIndex(upTo: memSize) % (memSize - dynamicOffsetValue)
3885
- }
+ let staticOffset = self.randomNonNegativeIndex(upTo: memSize - dynamicOffsetValue)
3886
3887
return (dynamicOffset, staticOffset)
3888
}
0 commit comments