Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Spearbit 99 #339

Merged
merged 2 commits into from
Sep 5, 2024
Merged

Spearbit 99 #339

merged 2 commits into from
Sep 5, 2024

Conversation

dianakocsis
Copy link
Contributor

Related Issue

Spearbit 99 _swapExactOutput... does not compare the params.amountOut to ActionConstants.OPEN_DELTA
https://github.com/spearbit-audits/review-uniswap-v4/issues/99

Description of changes

compare params.amountOut to ActionConstants.OPEN_DELTA

Copy link
Member

@snreynolds snreynolds left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this looks good.

it pains me that we don't use the mapTakeAmount and mapSettleAmount functions that we define in DeltaResolver.sol but I think its cause they added quite a bit more gas with extra casting. I wonder if we could overload those functions for uint128s now that we want to continue this logic in other places?

Copy link
Member

@snreynolds snreynolds left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ehhh ok I think you can't overload those functions. Let's send it.

& I'm commenting why we don't use those functions for future reference which is because they add extra gas in the router with the extra casting

@dianakocsis dianakocsis merged commit d1afb1b into main Sep 5, 2024
3 checks passed
@dianakocsis dianakocsis deleted the sb-99 branch September 5, 2024 20:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants