summaryrefslogtreecommitdiffstats
path: root/src/corelib/tools/qcontiguouscache.h
diff options
context:
space:
mode:
authorThiago Macieira <thiago.macieira@nokia.com>2009-10-28 11:47:35 (GMT)
committerThiago Macieira <thiago.macieira@nokia.com>2009-10-28 14:27:45 (GMT)
commit5b4b6b2be7b901ef9a29c37431998034730fa3d3 (patch)
tree9dd31b2f0af3f23462575c02f17eb33bdf9bb7e0 /src/corelib/tools/qcontiguouscache.h
parente83bb2fdfc2dc899526c8157fd8b77a68cdde9da (diff)
downloadQt-5b4b6b2be7b901ef9a29c37431998034730fa3d3.zip
Qt-5b4b6b2be7b901ef9a29c37431998034730fa3d3.tar.gz
Qt-5b4b6b2be7b901ef9a29c37431998034730fa3d3.tar.bz2
Initialise the reserved bits to 0.
This is future compatibility: we must rely on them being 0 in older versions of Qt. Reviewed-by: Bradley T. Hughes
Diffstat (limited to 'src/corelib/tools/qcontiguouscache.h')
-rw-r--r--src/corelib/tools/qcontiguouscache.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/corelib/tools/qcontiguouscache.h b/src/corelib/tools/qcontiguouscache.h
index b9d04b8..ef5b238 100644
--- a/src/corelib/tools/qcontiguouscache.h
+++ b/src/corelib/tools/qcontiguouscache.h
@@ -62,7 +62,7 @@ struct Q_CORE_EXPORT QContiguousCacheData
int start;
int offset;
uint sharable : 1;
- // uint unused : 31;
+ uint reserved : 31;
// total is 24 bytes (HP-UX aCC: 40 bytes)
// the next entry is already aligned to 8 bytes
@@ -186,6 +186,7 @@ void QContiguousCache<T>::detach_helper()
x.d->offset = d->offset;
x.d->alloc = d->alloc;
x.d->sharable = true;
+ x.d->reserved = 0;
T *dest = x.p->array + x.d->start;
T *src = p->array + d->start;