Use fixed preallocation instead of costly GetSerializeSize
commitd59a518466f6b9012666a3f9392ec12fff8830b5
authorPieter Wuille <pieter.wuille@gmail.com>
Sat, 29 Oct 2016 02:12:39 +0000 (28 19:12 -0700)
committerPieter Wuille <pieter.wuille@gmail.com>
Mon, 7 Nov 2016 21:56:27 +0000 (7 13:56 -0800)
treed851ca45a75edab810626eed6708d11107a24dea
parent25a211aa9edfeccc1e65bf699e0b32619cef2157
Use fixed preallocation instead of costly GetSerializeSize

Dbwrapper used GetSerializeSize() to compute the size of the buffer
to preallocate. For some cases (specifically: CCoins) this requires
a costly compression call. Avoid this by just using fixed size
preallocations instead.
src/dbwrapper.h