aboutsummaryrefslogtreecommitdiff
path: root/src/wallet.h
diff options
context:
space:
mode:
authorPieter Wuille <pieter.wuille@gmail.com>2014-08-07 23:00:01 +0200
committerWladimir J. van der Laan <laanwj@gmail.com>2014-08-18 15:34:29 +0200
commita78996503fc5a3e9f80741d6546fdb7eaf18feef (patch)
tree9b6706a60a9a8dc6de52052f2830fb33355a3ea2 /src/wallet.h
parentd78e4312b248661c7a5b10ab0f2cd13e81369cd7 (diff)
Add a way to limit deserialized string lengths
and use it for most strings being serialized. Rebased-From: 216e9a4
Diffstat (limited to 'src/wallet.h')
-rw-r--r--src/wallet.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/wallet.h b/src/wallet.h
index 88ee87196b..2d4b18dccd 100644
--- a/src/wallet.h
+++ b/src/wallet.h
@@ -756,7 +756,7 @@ public:
READWRITE(vchPrivKey);
READWRITE(nTimeCreated);
READWRITE(nTimeExpires);
- READWRITE(strComment);
+ READWRITE(LIMITED_STRING(strComment, 65536));
)
};
@@ -831,7 +831,7 @@ public:
// Note: strAccount is serialized as part of the key, not here.
READWRITE(nCreditDebit);
READWRITE(nTime);
- READWRITE(strOtherAccount);
+ READWRITE(LIMITED_STRING(strOtherAccount, 65536));
if (!fRead)
{
@@ -847,7 +847,7 @@ public:
}
}
- READWRITE(strComment);
+ READWRITE(LIMITED_STRING(strComment, 65536));
size_t nSepPos = strComment.find("\0", 0, 1);
if (fRead)