diff options
-rw-r--r-- | .qmake.conf | 2 | ||||
-rw-r--r-- | src/positioningquick/qdeclarativepositionsource.cpp | 6 |
2 files changed, 7 insertions, 1 deletions
diff --git a/.qmake.conf b/.qmake.conf index 398f6638..062d6124 100644 --- a/.qmake.conf +++ b/.qmake.conf @@ -3,7 +3,7 @@ CONFIG += warning_clean DEFINES += QT_NO_JAVA_STYLE_ITERATORS QT_NO_LINKED_LIST -MODULE_VERSION = 5.15.4 +MODULE_VERSION = 5.15.5 # Adds a way to debug location. The define is needed for multiple subprojects as they # include the essential headers. diff --git a/src/positioningquick/qdeclarativepositionsource.cpp b/src/positioningquick/qdeclarativepositionsource.cpp index cf160541..5d7856ae 100644 --- a/src/positioningquick/qdeclarativepositionsource.cpp +++ b/src/positioningquick/qdeclarativepositionsource.cpp @@ -193,6 +193,12 @@ void QDeclarativePositionSource::setName(const QString &newName) */ void QDeclarativePositionSource::tryAttach(const QString &newName, bool useFallback) { + if (m_nmeaFile != nullptr || m_nmeaSocket != nullptr) { + if (!m_providerName.isEmpty()) + qWarning("Both nmeaSource and name parameters are specified. nmeaSource will be used."); + return; + } + const QString previousName = name(); const bool sourceExisted = m_positionSource; m_providerName = newName; |