Skip to content
This repository has been archived by the owner on Nov 6, 2020. It is now read-only.

Commit

Permalink
rpc: cap gas limit of local calls (#8943)
Browse files Browse the repository at this point in the history
  • Loading branch information
andresilva authored and 5chdn committed Jun 22, 2018
1 parent d5136ab commit 2171ad6
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions rpc/src/v1/helpers/fake_sign.rs
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
// along with Parity. If not, see <http://www.gnu.org/licenses/>.

use transaction::{Transaction, SignedTransaction, Action};
use ethereum_types::U256;

use jsonrpc_core::Error;
use v1::helpers::CallRequest;
Expand All @@ -29,7 +28,7 @@ pub fn sign_call(request: CallRequest, gas_cap: bool) -> Result<SignedTransactio
}
Some(gas) => gas,
None if gas_cap => max_gas,
None => U256::from(2) << 50,
None => max_gas * 10,
};
let from = request.from.unwrap_or(0.into());

Expand Down

0 comments on commit 2171ad6

Please sign in to comment.