script: do not change inputs

This commit is contained in:
Fedor Indutny 2014-05-06 13:30:32 +04:00
parent 7f0ea92a43
commit f787590efe
2 changed files with 4 additions and 3 deletions

View File

@ -112,6 +112,7 @@ Peer.prototype.broadcast = function broadcast(items) {
e: new EventEmitter(),
timeout: setTimeout(function() {
entry.e.emit('timeout');
clearInterval(entry.interval);
delete self._broadcast.map[key];
}, this._broadcast.timeout),

View File

@ -135,7 +135,7 @@ script.execute = function execute(s, stack, tx) {
if (!res)
return false;
} else {
stack.push([ res ? 1 : 0 ]);
stack.push(res ? [ 1 ] : []);
}
} else if (o === 'checksigverify' || o === 'checksig') {
@ -144,7 +144,7 @@ script.execute = function execute(s, stack, tx) {
var pub = stack.pop();
var sig = stack.pop();
var type = sig.pop();
var type = sig[sig.length - 1];
if (type !== 1)
return false;
@ -153,7 +153,7 @@ script.execute = function execute(s, stack, tx) {
if (!res)
return false;
} else {
stack.push([ res ? 1 : 0 ]);
stack.push(res ? [ 1 ] : []);
}
} else {
// Unknown operation