Commit 1b417fd7 authored by hjk's avatar hjk

Debugger: Use qtHookData to extract Qt version when possible

This avoids inferior calls, i.e. is faster and more robust.

Task-number: QTCREATORBUG-14350
Change-Id: I9f21eda6e2e3950eaaca90a35afb885e76e789d8
Reviewed-by: default avatarChristian Stenger <christian.stenger@theqtcompany.com>
parent 019e6188
......@@ -811,6 +811,14 @@ class Dumper(DumperBase):
return None
def qtVersion(self):
try:
# Only available with Qt 5.3+
qtversion = int(gdb.parse_and_eval("((void**)&qtHookData)[2]"))
self.qtVersion = lambda: qtversion
return qtversion
except:
pass
try:
version = self.qtVersionString()
(major, minor, patch) = version[version.find('"')+1:version.rfind('"')].split('.')
......
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