Debugger: Fix QFile dumper 64 bit for Qt6

32 bit offsets are mechanically adapted on the base that the size change
was due to five containers changing from one to three pointer in Qt6,
but this has not been checked.

Task-number: QTCREATORBUG-24098
Change-Id: I492485a720f75df5fdde3dedb2fcfe9e953f1ed7
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
hjk
2020-12-09 12:07:27 +01:00
parent 344802b8b2
commit 3b7aee724d

View File

@@ -652,7 +652,18 @@ def qdump__QFile(d, value):
# 9fc0965 and a373ffcd change the layout of the private structure
qtVersion = d.qtVersion()
is32bit = d.ptrSize() == 4
if qtVersion >= 0x050600 and d.qtTypeInfoVersion() >= 17:
if qtVersion >= 0x060000:
# FIXME: values 0 are wrong. As the file name is the
# only direct member of QFilePrivate, the offsets are
# equal to sizeof(QFileDevicePrivate), the base class.
if d.isWindowsTarget():
if d.isMsvcTarget():
offset = 0 if is32bit else 304
else:
offset = 0 if is32bit else 304
else:
offset = 0 if is32bit else 304
elif qtVersion >= 0x050600 and d.qtTypeInfoVersion() >= 17:
# Some QRingBuffer member got removed in 8f92baf5c9
if d.isWindowsTarget():
if d.isMsvcTarget():