The _runSwap returns a bool value i.e returns True if only dexSwap is performed or returns false if _gmxSwap is performed. According to the natspec if the returned value is true it indicates the swap is completed and if its false it indicates swap should continue.
These are the instances where _runSwap() is called in different scenarios
in runNextAction 1](https://github.com/CodeHawks-Contests/2025-02-gamma/blob/e5b98627a4c965e203dbb616a5f43ec194e7631a/contracts/PerpetualVault.sol#L358-L358),2,3
As you can see in all the above instances the runSwap is called its return value is not made use of
Manual review
make use of the return value as intended and mentioned in the natspec
Please read the CodeHawks documentation to know which submissions are valid. If you disagree, provide a coded PoC and explain the real likelihood and the detailed impact on the mainnet without any supposition (if, it could, etc) to prove your point.
Please read the CodeHawks documentation to know which submissions are valid. If you disagree, provide a coded PoC and explain the real likelihood and the detailed impact on the mainnet without any supposition (if, it could, etc) to prove your point.
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.