Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Warning! Error encountered during contract execution [Bad jump destination]
- function start(address seller, address thirdParty) returns (uint escrowId) {
- escrowId = numEscrows;
- numEscrows++;
- escrow e;
- e.thirdParty = thirdParty;
- e.seller = seller;
- e.buyer = msg.sender;
- e.amount = msg.value;
- e.recipient = seller;
- e.status = 1; // started
- escrows[escrowId] = e;
- return escrowId;
- }
- pragma solidity ^0.4.0;
- contract Ballot {
- struct Escrow {
- address thirdParty;
- address seller;
- address buyer;
- uint amount;
- address recipient;
- uint status;
- }
- uint numEscrows;
- mapping (uint => Escrow) escrows;
- function start(address seller, address thirdParty) returns (uint escrowId) {
- escrowId = numEscrows;
- numEscrows++;
- Escrow memory e;
- e.thirdParty = thirdParty;
- e.seller = seller;
- e.buyer = msg.sender;
- e.amount = msg.value;
- e.recipient = seller;
- e.status = 1; // started
- escrows[escrowId] = e;
- return escrowId;
- }
- function start1(address seller, address thirdParty) returns (uint escrowId) {
- escrows[numEscrows].thirdParty = thirdParty;
- escrows[numEscrows].seller = seller;
- escrows[numEscrows].buyer = msg.sender;
- escrows[numEscrows].amount = msg.value;
- escrows[numEscrows].recipient = seller;
- escrows[numEscrows].status = 1; // started
- numEscrows++;
- return numEscrows;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement