diff --git a/src/plugins/debugger/debuggerprotocol.cpp b/src/plugins/debugger/debuggerprotocol.cpp index 26b0ad1d60e..f3515afe3a5 100644 --- a/src/plugins/debugger/debuggerprotocol.cpp +++ b/src/plugins/debugger/debuggerprotocol.cpp @@ -423,12 +423,16 @@ QByteArray DebuggerResponse::toString() const // ////////////////////////////////////////////////////////////////////////////////// +// Tested in tests/auto/debugger/tst_gdb.cpp + void extractGdbVersion(const QString &msg, int *gdbVersion, int *gdbBuildVersion, bool *isMacGdb, bool *isQnxGdb) { const QChar dot(QLatin1Char('.')); - const bool ignoreParenthesisContent = msg.contains(QLatin1String("rubenvb")); + const bool ignoreParenthesisContent = msg.contains(QLatin1String("rubenvb")) + || msg.contains(QLatin1String("openSUSE")); + const QChar parOpen(QLatin1Char('(')); const QChar parClose(QLatin1Char(')')); diff --git a/tests/auto/debugger/tst_gdb.cpp b/tests/auto/debugger/tst_gdb.cpp index 2b7d079d511..9f65b4fd20f 100644 --- a/tests/auto/debugger/tst_gdb.cpp +++ b/tests/auto/debugger/tst_gdb.cpp @@ -61,9 +61,7 @@ void tst_gdb::version() bool qnx = true; Debugger::Internal::extractGdbVersion(msg, &v, &bv, &mac, &qnx); //qDebug() << msg << " -> " << v << bv << mac << qnx; - QEXPECT_FAIL("openSUSE 13.1", "Not done yet", Continue); QCOMPARE(v, gdbVersion); - QEXPECT_FAIL("openSUSE 13.1", "Not done yet", Continue); QCOMPARE(bv, gdbBuildVersion); QCOMPARE(mac, isMacGdb); QCOMPARE(qnx, isQnxGdb); @@ -124,6 +122,10 @@ void tst_gdb::version_data() QTest::newRow("openSUSE 13.1") << "GNU gdb (GDB; openSUSE 13.1) 7.6.50.20130731-cvs" << 70650 << 20130731 << false << false; + + QTest::newRow("openSUSE 13.2") + << "GNU gdb (GDB; openSUSE 13.2) 7.8" + << 70800 << 0 << false << false; } static QString chopConst(QString type)