summaryrefslogtreecommitdiffstats
path: root/src/corelib/tools/qbytearray.cpp
diff options
context:
space:
mode:
authorMarkus Goetz <Markus.Goetz@nokia.com>2010-01-21 10:28:00 (GMT)
committerMarkus Goetz <Markus.Goetz@nokia.com>2010-01-21 11:48:09 (GMT)
commit694be5a31be7e24761753ab9eccd87e8d08607e0 (patch)
treeacc4fcf9eba015cbbdd202775bd2230cf8af8e5f /src/corelib/tools/qbytearray.cpp
parent967b6980372b3a3b988d2284bdd10b8154482680 (diff)
downloadQt-694be5a31be7e24761753ab9eccd87e8d08607e0.zip
Qt-694be5a31be7e24761753ab9eccd87e8d08607e0.tar.gz
Qt-694be5a31be7e24761753ab9eccd87e8d08607e0.tar.bz2
qUncompress: Fix terminating \0
Task-number: 6666 Reviewed-by: Harald Fernengel <harald.fernengel@nokia.com>
Diffstat (limited to 'src/corelib/tools/qbytearray.cpp')
-rw-r--r--src/corelib/tools/qbytearray.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/corelib/tools/qbytearray.cpp b/src/corelib/tools/qbytearray.cpp
index 4049925..556093f 100644
--- a/src/corelib/tools/qbytearray.cpp
+++ b/src/corelib/tools/qbytearray.cpp
@@ -561,6 +561,7 @@ QByteArray qUncompress(const uchar* data, int nbytes)
d->ref = 1;
d->alloc = d->size = len;
d->data = d->array;
+ d->array[len] = 0;
return QByteArray(d.take(), 0, 0);