[Interest] Strange behaviour of QByteArray reserve/reallocation mechansim
Bernhard
private at bernhard-lindner.de
Sun Nov 9 10:34:28 CET 2014
Hi there!
I just experienced a strange behavior of QByteArray regarding its internal
reallocation behavior. Actually that behavior stops me from using
capacity()/reserve() to optimize the allocation behavior and its seem to me
that under current conditions reserve() is more or less useless. Using the
current implementation there is no way of avoiding continuous reallocations
while using QByteArray with data of different lengths.
Please see the following SO post (please tell me if it is not allowed to
post such links in this ML):
http://stackoverflow.com/questions/26821207/internal-reallocation-behaviour-
of-qbytearray-vs-reserve
Is this actually desired behavior? Is it a bug?
--
Kind Regards
Bernhard Lindner
More information about the Interest
mailing list