auto_ptr semantics are a bit odd

This commit is contained in:
JoelKatz
2012-09-28 23:35:40 -07:00
parent 609edfddbd
commit b6c73c87d4

View File

@@ -884,7 +884,7 @@ STAmount STAmount::convertToInternalAmount(uint64 displayAmount, uint64 totalNow
STAmount STAmount::deserialize(SerializerIterator& it)
{
auto_ptr<STAmount> s = construct(it, sfGeneric);
std::auto_ptr<STAmount> s(dynamic_cast<STAmount*>(construct(it, sfGeneric)));
STAmount ret(*s);
return ret;
}