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

Fix incoming transfer handlers #382

Merged
merged 2 commits into from
Jul 17, 2024
Merged

Fix incoming transfer handlers #382

merged 2 commits into from
Jul 17, 2024

Conversation

hieronx
Copy link
Contributor

@hieronx hieronx commented Jul 17, 2024

No description provided.

} else if (call == MessagesLib.Call.TransferTrancheTokens) {
handleTransferTrancheTokens(
message.toUint64(1), message.toBytes16(9), message.toAddress(66), message.toUint128(98)
message.toUint64(1), message.toBytes16(9), message.toAddress(34), message.toUint128(66)
Copy link
Contributor

Choose a reason for hiding this comment

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

tobytes16(9) so this is 15 additional bytes of message data + 9 the offset , that's 25. So why message.toAddress(34)? What's between 25th and 34th ?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The destination domain: uint8 for the enum + uint64 for the chain id = 9 bytes. See the code in MockCentrifugeChain

@hieronx hieronx merged commit 223a0f3 into main Jul 17, 2024
3 checks passed
@peculiarity peculiarity deleted the fix-incoming-handlers branch July 17, 2024 10:28
Copy link

Coverage after merging fix-incoming-handlers into main will be

99.70%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
src
   Auth.sol100%100%100%100%
   CentrifugeRouter.sol91.11%65.91%100%99.07%113, 113, 125, 125, 179, 179, 204, 204, 208, 208, 225, 225, 47, 54, 54, 54
   ERC7540Vault.sol98.88%92.31%100%100%150, 150
   Escrow.sol100%100%100%100%
   InvestmentManager.sol99.04%100%93.02%100%
   PoolManager.sol98.98%100%88.46%100%
   Root.sol98.68%100%92.86%100%
src/admin
   Guardian.sol92.59%100%100%85.71%65–66
src/factories
   ERC7540VaultFactory.sol100%100%100%100%
   TrancheFactory.sol100%100%100%100%
   TransferProxyFactory.sol100%100%100%100%
src/gateway
   GasService.sol100%100%100%100%
   Gateway.sol99.27%97.78%100%100%242, 247
src/gateway/adapters/axelar
   Adapter.sol100%100%100%100%
   Forwarder.sol100%100%100%100%
src/token
   ERC20.sol100%100%100%100%
   RestrictionManager.sol100%100%100%100%
   Tranche.sol98.21%100%94.12%100%

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.

3 participants