From e679ec969c8b22c676ebb10bea1038f6c8f13b33 Mon Sep 17 00:00:00 2001 From: Gavin Andresen Date: Mon, 3 Oct 2011 13:05:43 -0400 Subject: OP_EVAL implementation OP_EVAL is a new opcode that evaluates an item on the stack as a script. It enables a new type of bitcoin address that needs an arbitrarily complex script to redeem. --- src/db.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/db.cpp') diff --git a/src/db.cpp b/src/db.cpp index 7195e065e..52ad695c7 100644 --- a/src/db.cpp +++ b/src/db.cpp @@ -934,6 +934,15 @@ int CWalletDB::LoadWallet(CWallet* pwallet) if (nMinVersion > CLIENT_VERSION) return DB_TOO_NEW; } + else if (strType == "cscript") + { + uint160 hash; + ssKey >> hash; + std::vector script; + ssValue >> script; + if (!pwallet->LoadCScript(hash, script)) + return DB_CORRUPT; + } } pcursor->close(); } -- cgit v1.2.3 From 2a45a494b0bec6a0f1fc6ab7f26c260b85e7ff3e Mon Sep 17 00:00:00 2001 From: Gavin Andresen Date: Tue, 8 Nov 2011 13:20:29 -0500 Subject: Use block times for 'hard' OP_EVAL switchover, and refactored EvalScript so it takes a flag for how to interpret OP_EVAL. Also increased IsStandard size of scriptSigs to 500 bytes, so a 3-of-3 multisig transaction IsStandard. --- src/db.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/db.cpp') diff --git a/src/db.cpp b/src/db.cpp index 52ad695c7..f43b2a565 100644 --- a/src/db.cpp +++ b/src/db.cpp @@ -938,7 +938,7 @@ int CWalletDB::LoadWallet(CWallet* pwallet) { uint160 hash; ssKey >> hash; - std::vector script; + CScript script; ssValue >> script; if (!pwallet->LoadCScript(hash, script)) return DB_CORRUPT; -- cgit v1.2.3