diff options
author | Pieter Wuille <pieter.wuille@gmail.com> | 2014-08-21 00:49:32 +0200 |
---|---|---|
committer | Kamil Domanski <kdomanski@kdemail.net> | 2014-08-31 02:18:42 +0200 |
commit | 31e9a8384a77947f6777d035992f4734618ed206 (patch) | |
tree | 9a055fbae630bad4b7982a5aae1294a9579382cb /src/qt/recentrequeststablemodel.h | |
parent | 84881f8c472cc67dc757686eb7dc3b495b13cab8 (diff) |
Use CSizeComputer to avoid counting sizes in SerializationOp
Diffstat (limited to 'src/qt/recentrequeststablemodel.h')
-rw-r--r-- | src/qt/recentrequeststablemodel.h | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/src/qt/recentrequeststablemodel.h b/src/qt/recentrequeststablemodel.h index 581d7b2c5e..a558aa4942 100644 --- a/src/qt/recentrequeststablemodel.h +++ b/src/qt/recentrequeststablemodel.h @@ -27,9 +27,8 @@ public: IMPLEMENT_SERIALIZE; template <typename Stream, typename Operation> - inline size_t SerializationOp(Stream& s, Operation ser_action, int nType, int nVersion) { - size_t nSerSize = 0; - bool fRead = boost::is_same<Operation, CSerActionUnserialize>(); + inline void SerializationOp(Stream& s, Operation ser_action, int nType, int nVersion) { + bool fRead = ser_action.ForRead(); RecentRequestEntry* pthis = const_cast<RecentRequestEntry*>(this); @@ -42,9 +41,7 @@ public: READWRITE(recipient); if (fRead) - pthis->date = QDateTime::fromTime_t(nDate); - - return nSerSize; + date = QDateTime::fromTime_t(nDate); } }; |