Submitted by Chom
XC20Wrapper.sol#L124-L126
XC20Wrapper may lose received token forever if LocalAsset(xc20).mint is reverted indefinitely.
Similar to ERC20, the spec said that if mint returns false it means minting is failed. But it is commonly revert instead of returning false which is also a minting failure. XC20 may revert on minting as well and common sense also guiding programmers to use the revert pattern instead of returning false.
This case is not handled if SC20 minting is reverted indefinitely. No matter how hard you retry the GMP message execution, it always fail thus the token get locked forever.
Use try catch
re1ro (Axelar) acknowledged and commented:
Alex the Entreprenerd (judge) commented:
