Commit e5c38532 authored by ck's avatar ck
Browse files

Debugger: Fixed dumper autotests.

Recent changes to QObject and QSharedPointer broke the dumper
auto tests.
parent b6087aff
......@@ -117,6 +117,7 @@ public:
void *currentChildBeingDeleted;
void *declarativeData;
void *objectGuards;
QAtomicPointer<void> sharedRefCount;
int *deleteWatch;
#endif
};
......
......@@ -1868,13 +1868,13 @@ void tst_Debugger::dumpQSharedPointerHelper(QSharedPointer<T> &ptr)
QByteArray expected("value='");
QString val1 = ptr.isNull() ? "<null>" : valToString(*ptr.data());
QString val2 = isSimpleType(dummy) ? val1 : "";
const QAtomicInt *weakAddr;
const QAtomicInt *strongAddr;
const int *weakAddr;
const int *strongAddr;
int weakValue;
int strongValue;
if (!ptr.isNull()) {
weakAddr = &Cheater::getData(ptr)->weakref;
strongAddr = &Cheater::getData(ptr)->strongref;
weakAddr = reinterpret_cast<const int *>(&Cheater::getData(ptr)->weakref);
strongAddr = reinterpret_cast<const int *>(&Cheater::getData(ptr)->strongref);
weakValue = *weakAddr;
strongValue = *strongAddr;
} else {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment