I don't exactly know. What I do know is that it's what encodeVariable()
returns in its outsize parameter. The element class could probably use a
method like "encodedSize()". At any rate, I increased the size by 2 for
each element, because later in the writeFile method padding zeroes are
written, so the size that actually gets written is encodedSize()+2:
memcpy(ptr, foo, outsize);
ptr += outsize;
*ptr++ = 0;
In the last line, ptr is incremented by one, making the length that was
actually written outsize + 1. Which is less than what we allocated prior
to my patch.
Bastiaan
On Mon, 11 Feb 2008, strk wrote:
+ size += el->getName().size() + el->getLength() + 7;
What are these magic numbers exactly ?
--strk;
_______________________________________________
Gnash-commit mailing list
Gnash-commit@gnu.org
http://lists.gnu.org/mailman/listinfo/gnash-commit