summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/bluetooth/qbluetoothdevicediscoveryagent.h2
-rw-r--r--src/bluetooth/qbluetoothlocaldevice.h4
-rw-r--r--src/bluetooth/qbluetoothserver.h2
-rw-r--r--src/bluetooth/qbluetoothservicediscoveryagent.h2
-rw-r--r--src/bluetooth/qbluetoothsocket.h2
-rw-r--r--src/bluetooth/qlowenergycontroller.h2
-rw-r--r--src/nfc/qnearfieldmanager_qnx.cpp4
-rw-r--r--src/nfc/qnearfieldsharetarget.h2
-rw-r--r--src/tools/sdpscanner/main.cpp16
9 files changed, 20 insertions, 16 deletions
diff --git a/src/bluetooth/qbluetoothdevicediscoveryagent.h b/src/bluetooth/qbluetoothdevicediscoveryagent.h
index 700d8af7..656604ac 100644
--- a/src/bluetooth/qbluetoothdevicediscoveryagent.h
+++ b/src/bluetooth/qbluetoothdevicediscoveryagent.h
@@ -36,7 +36,7 @@
#include <QtBluetooth/qbluetoothglobal.h>
-#include <QObject>
+#include <QtCore/QObject>
#include <QtBluetooth/QBluetoothDeviceInfo>
#include <QtBluetooth/QBluetoothAddress>
diff --git a/src/bluetooth/qbluetoothlocaldevice.h b/src/bluetooth/qbluetoothlocaldevice.h
index 90c113d7..bcb39bda 100644
--- a/src/bluetooth/qbluetoothlocaldevice.h
+++ b/src/bluetooth/qbluetoothlocaldevice.h
@@ -36,9 +36,9 @@
#include <QtBluetooth/qbluetoothglobal.h>
-#include <QObject>
+#include <QtCore/QObject>
#include <QtCore/QList>
-#include <QString>
+#include <QtCore/QString>
#include <QtBluetooth/QBluetoothHostInfo>
diff --git a/src/bluetooth/qbluetoothserver.h b/src/bluetooth/qbluetoothserver.h
index 22932a94..951b47f4 100644
--- a/src/bluetooth/qbluetoothserver.h
+++ b/src/bluetooth/qbluetoothserver.h
@@ -37,7 +37,7 @@
#include <QtBluetooth/qbluetoothglobal.h>
-#include <QObject>
+#include <QtCore/QObject>
#include <QtBluetooth/QBluetoothAddress>
#include <QtBluetooth/qbluetooth.h>
diff --git a/src/bluetooth/qbluetoothservicediscoveryagent.h b/src/bluetooth/qbluetoothservicediscoveryagent.h
index 2203721f..d15a1d8d 100644
--- a/src/bluetooth/qbluetoothservicediscoveryagent.h
+++ b/src/bluetooth/qbluetoothservicediscoveryagent.h
@@ -36,7 +36,7 @@
#include <QtBluetooth/qbluetoothglobal.h>
-#include <QObject>
+#include <QtCore/QObject>
#include <QtBluetooth/QBluetoothServiceInfo>
#include <QtBluetooth/QBluetoothUuid>
diff --git a/src/bluetooth/qbluetoothsocket.h b/src/bluetooth/qbluetoothsocket.h
index 6caca2a0..b073ada3 100644
--- a/src/bluetooth/qbluetoothsocket.h
+++ b/src/bluetooth/qbluetoothsocket.h
@@ -40,7 +40,7 @@
#include <QtBluetooth/QBluetoothUuid>
#include <QtBluetooth/QBluetoothServiceInfo>
-#include <QIODevice>
+#include <QtCore/QIODevice>
#include <QtNetwork/QAbstractSocket>
QT_BEGIN_NAMESPACE
diff --git a/src/bluetooth/qlowenergycontroller.h b/src/bluetooth/qlowenergycontroller.h
index b125fc09..7906d257 100644
--- a/src/bluetooth/qlowenergycontroller.h
+++ b/src/bluetooth/qlowenergycontroller.h
@@ -34,7 +34,7 @@
#ifndef QLOWENERGYCONTROLLER_H
#define QLOWENERGYCONTROLLER_H
-#include <QObject>
+#include <QtCore/QObject>
#include <QtBluetooth/QBluetoothAddress>
#include <QtBluetooth/QBluetoothDeviceInfo>
#include <QtBluetooth/QBluetoothUuid>
diff --git a/src/nfc/qnearfieldmanager_qnx.cpp b/src/nfc/qnearfieldmanager_qnx.cpp
index 7ed79f84..2c3c7077 100644
--- a/src/nfc/qnearfieldmanager_qnx.cpp
+++ b/src/nfc/qnearfieldmanager_qnx.cpp
@@ -85,7 +85,7 @@ void QNearFieldManagerPrivateImpl::stopTargetDetection()
int QNearFieldManagerPrivateImpl::registerNdefMessageHandler(QObject *object, const QMetaMethod &method)
{
QList<QByteArray> filterList;
- filterList += "*";
+ filterList += '*';
QNXNFCManager::instance()->updateNdefFilters(filterList, this);
ndefMessageHandlers.append(QPair<QPair<int, QObject *>, QMetaMethod>(QPair<int, QObject *>(m_handlerID, object), method));
@@ -180,7 +180,7 @@ void QNearFieldManagerPrivateImpl::updateNdefFilter()
qQNXNFCDebug() << "Updating NDEF filter";
QList<QByteArray> filterList;
if (ndefMessageHandlers.size() > 0) { ///SUbscribe for all ndef messages
- filterList += "*";
+ filterList += '*';
QNXNFCManager::instance()->updateNdefFilters(filterList, this);
} else if (ndefFilterHandlers.size() > 0){
for (int i = 0; i < ndefFilterHandlers.count(); i++) {
diff --git a/src/nfc/qnearfieldsharetarget.h b/src/nfc/qnearfieldsharetarget.h
index 596230d1..cc85086f 100644
--- a/src/nfc/qnearfieldsharetarget.h
+++ b/src/nfc/qnearfieldsharetarget.h
@@ -36,7 +36,7 @@
#define QNEARFIELDSHARETARGET_H
#include <QtCore/QObject>
-#include <QFileInfo>
+#include <QtCore/QFileInfo>
#include <QtNfc/QNdefMessage>
#include <QtNfc/QNearFieldShareManager>
diff --git a/src/tools/sdpscanner/main.cpp b/src/tools/sdpscanner/main.cpp
index 35c08e0c..1efb6de2 100644
--- a/src/tools/sdpscanner/main.cpp
+++ b/src/tools/sdpscanner/main.cpp
@@ -141,9 +141,13 @@ static void parseAttributeValues(sdp_data_t *data, int indentation, QByteArray &
QByteArray text = QByteArray::fromRawData(data->val.str, data->unitSize);
bool hasNonPrintableChar = false;
- for (int i = 0; i < text.count() && !hasNonPrintableChar; i++) {
- if (!isprint(text[i])) {
+ for (int i = 0; i < text.count(); i++) {
+ if (text[i] == '\0') {
+ text.resize(i); // cut trailing content
+ break;
+ } else if (!isprint(text[i])) {
hasNonPrintableChar = true;
+ text.resize(text.indexOf('\0')); // cut trailing content
break;
}
}
@@ -152,10 +156,10 @@ static void parseAttributeValues(sdp_data_t *data, int indentation, QByteArray &
xmlOutput.append("encoding=\"hex\" value=\"");
xmlOutput.append(text.toHex());
} else {
- text.replace("&", "&amp");
- text.replace("<", "&lt");
- text.replace(">", "&gt");
- text.replace("\"", "&quot");
+ text.replace('&', "&amp;");
+ text.replace('<', "&lt;");
+ text.replace('>', "&gt;");
+ text.replace('"', "&quot;");
xmlOutput.append("value=\"");
xmlOutput.append(text);