diff options
author | Leonard Lee <leonard.lee@digia.com> | 2013-08-19 11:29:32 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2013-08-21 13:27:47 +0200 |
commit | 35fd077c803b7465325a94f02da3c4e10cb55bee (patch) | |
tree | 7d37418f9b5137e1b269b1c26fa8d11a62772c4e | |
parent | 8b540f68a8404e4b9e3ac65a22c11416a91ee749 (diff) |
Specify maximum array size for QByteArray.
Task-number: QTBUG-33037
Change-Id: I3f39b1498fc70614402fca2281ffbd1a6ec4cf3f
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
-rw-r--r-- | src/corelib/tools/qbytearray.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/corelib/tools/qbytearray.cpp b/src/corelib/tools/qbytearray.cpp index 6ce17e5e13..e993855e7e 100644 --- a/src/corelib/tools/qbytearray.cpp +++ b/src/corelib/tools/qbytearray.cpp @@ -645,6 +645,8 @@ static inline char qToLower(char c) store raw binary data, and when memory conservation is critical (e.g., with Qt for Embedded Linux). + The maximum array size of a QByteArray is under 2^30. + One way to initialize a QByteArray is simply to pass a \c{const char *} to its constructor. For example, the following code creates a byte array of size 5 containing the data "Hello": |