Applied patch from Bernhard Herzog to fix the Crash in Qt.