Permit memos up to 1Kb.

* Overlong memos are basically treated like invalid signatures.
* Ability to clear message key.
This commit is contained in:
David Schwartz
2014-02-19 15:28:43 -08:00
committed by Vinnie Falco
parent ae649ec917
commit 370bfb7a22
10 changed files with 62 additions and 5 deletions

View File

@@ -832,6 +832,25 @@ const STAmount& STObject::getFieldAmount (SField::ref field) const
return *cf;
}
const STArray& STObject::getFieldArray (SField::ref field) const
{
static STArray empty;
const SerializedType* rf = peekAtPField (field);
if (!rf) throw std::runtime_error ("Field not found");
SerializedTypeID id = rf->getSType ();
if (id == STI_NOTPRESENT) return empty;
const STArray* cf = dynamic_cast<const STArray*> (rf);
if (!cf)
throw std::runtime_error ("Wrong field type");
return *cf;
}
const STPathSet& STObject::getFieldPathSet (SField::ref field) const
{
static STPathSet empty;