In ethereum smart contract it’s possible to call functions of other contracts. This can be done using such line of code:
However there exists 2 risks. Reentrancy Attack and Gas depletion.
Abount Gas deppletion it’s possible that that malicious contract consumes a huge amount of gas and finally revert.
My question is that how much gas should be set for such external function call in order to avoid gas depletion and on the other hand run the honest functions?