diff --git a/src/KDSoapClient/KDDateTime.h b/src/KDSoapClient/KDDateTime.h index a50293f77..788a554ac 100644 --- a/src/KDSoapClient/KDDateTime.h +++ b/src/KDSoapClient/KDDateTime.h @@ -46,7 +46,7 @@ class KDSOAP_EXPORT KDDateTime : public QDateTime * Implicit constructor from a QDateTime. * Sets the timeZone to "local", i.e. empty */ - KDDateTime(const QDateTime &); + /*implicit*/ KDDateTime(const QDateTime &); KDDateTime &operator=(const KDDateTime &); ~KDDateTime(); diff --git a/src/KDSoapClient/KDSoap.h b/src/KDSoapClient/KDSoap.h index acfdf08fe..d424e3f18 100644 --- a/src/KDSoapClient/KDSoap.h +++ b/src/KDSoapClient/KDSoap.h @@ -21,6 +21,9 @@ ** **********************************************************************/ +#ifndef KDSOAP_H +#define KDSOAP_H + #include "KDSoapClientInterface.h" #include "KDSoapMessage.h" #include "KDSoapPendingCall.h" @@ -29,3 +32,4 @@ #include "KDSoapAuthentication.h" #include "KDSoapNamespaceManager.h" +#endif diff --git a/src/KDSoapClient/KDSoapClientInterface.cpp b/src/KDSoapClient/KDSoapClientInterface.cpp index b46fa409a..3becdba87 100644 --- a/src/KDSoapClient/KDSoapClientInterface.cpp +++ b/src/KDSoapClient/KDSoapClientInterface.cpp @@ -228,7 +228,7 @@ void KDSoapClientInterface::ignoreSslErrors(const QList &errors) void KDSoapClientInterfacePrivate::setupReply(QNetworkReply *reply) { if (m_ignoreSslErrors) { - QObject::connect(reply, SIGNAL(sslErrors(const QList&)), reply, SLOT(ignoreSslErrors())); + QObject::connect(reply, SIGNAL(sslErrors(QList)), reply, SLOT(ignoreSslErrors())); } else { #ifndef QT_NO_OPENSSL reply->ignoreSslErrors(m_ignoreErrorsList); diff --git a/src/KDSoapClient/KDSoapClientThread_p.h b/src/KDSoapClient/KDSoapClientThread_p.h index 1184537fc..fef093156 100644 --- a/src/KDSoapClient/KDSoapClientThread_p.h +++ b/src/KDSoapClient/KDSoapClientThread_p.h @@ -64,7 +64,7 @@ class KDSoapThreadTask : public QObject { Q_OBJECT public: - KDSoapThreadTask(KDSoapThreadTaskData* data) + explicit KDSoapThreadTask(KDSoapThreadTaskData* data) : m_data(data) {} void process(QNetworkAccessManager& accessManager); diff --git a/src/KDSoapClient/KDSoapMessage.h b/src/KDSoapClient/KDSoapMessage.h index 3efacff6c..46ea864ca 100644 --- a/src/KDSoapClient/KDSoapMessage.h +++ b/src/KDSoapClient/KDSoapMessage.h @@ -160,7 +160,7 @@ class KDSOAP_EXPORT KDSoapMessage : public KDSoapValue * Set of headers that can be provided when making a SOAP call. * \see KDSoapClientInterface */ -class KDSOAP_EXPORT KDSoapHeaders : public QList +class KDSOAP_EXPORT KDSoapHeaders : public QList //krazy:exclude=dpointer { public: /** diff --git a/src/KDSoapClient/KDSoapMessageReader_p.h b/src/KDSoapClient/KDSoapMessageReader_p.h index 62d9f6352..fe3a0ab9e 100644 --- a/src/KDSoapClient/KDSoapMessageReader_p.h +++ b/src/KDSoapClient/KDSoapMessageReader_p.h @@ -21,8 +21,8 @@ ** **********************************************************************/ -#ifndef KSOAPMESSAGEREADER_P_H -#define KSOAPMESSAGEREADER_P_H +#ifndef KDSOAPMESSAGEREADER_P_H +#define KDSOAPMESSAGEREADER_P_H #include "KDSoapMessage.h" diff --git a/src/KDSoapClient/KDSoapNamespaceManager.h b/src/KDSoapClient/KDSoapNamespaceManager.h index 37ce59d56..99e25f833 100644 --- a/src/KDSoapClient/KDSoapNamespaceManager.h +++ b/src/KDSoapClient/KDSoapNamespaceManager.h @@ -29,7 +29,7 @@ /** * Repository of namespaces */ -class KDSOAP_EXPORT KDSoapNamespaceManager +class KDSOAP_EXPORT KDSoapNamespaceManager //krazy:exclude=dpointer { public: static QString xmlSchema1999(); @@ -41,7 +41,7 @@ class KDSOAP_EXPORT KDSoapNamespaceManager static QString soapEncoding(); static QString soapEncoding200305(); -private: // TODO instanciate to handle custom namespaces per clientinterface +private: // TODO instantiate to handle custom namespaces per clientinterface KDSoapNamespaceManager(); }; diff --git a/src/KDSoapClient/KDSoapNamespacePrefixes.cpp b/src/KDSoapClient/KDSoapNamespacePrefixes.cpp index 1d0c7f38a..6b62b39d9 100644 --- a/src/KDSoapClient/KDSoapNamespacePrefixes.cpp +++ b/src/KDSoapClient/KDSoapNamespacePrefixes.cpp @@ -20,8 +20,8 @@ ** clear to you. ** **********************************************************************/ -#include "KDSoapClientInterface_p.h" #include "KDSoapNamespacePrefixes_p.h" +#include "KDSoapClientInterface_p.h" #include "KDSoapNamespaceManager.h" void KDSoapNamespacePrefixes::writeStandardNamespaces(QXmlStreamWriter& writer, diff --git a/src/KDSoapClient/KDSoapNamespacePrefixes_p.h b/src/KDSoapClient/KDSoapNamespacePrefixes_p.h index b123a8031..33435678e 100644 --- a/src/KDSoapClient/KDSoapNamespacePrefixes_p.h +++ b/src/KDSoapClient/KDSoapNamespacePrefixes_p.h @@ -20,8 +20,8 @@ ** clear to you. ** **********************************************************************/ -#ifndef KDSOAPNAMESPACESPREFIXES_H -#define KDSOAPNAMESPACESPREFIXES_H +#ifndef KDSOAPNAMESPACEPREFIXES_P_H +#define KDSOAPNAMESPACEPREFIXES_P_H #include #include diff --git a/src/KDSoapClient/KDSoapSslHandler.cpp b/src/KDSoapClient/KDSoapSslHandler.cpp index aee689d74..e27873e2e 100644 --- a/src/KDSoapClient/KDSoapSslHandler.cpp +++ b/src/KDSoapClient/KDSoapSslHandler.cpp @@ -21,11 +21,10 @@ ** **********************************************************************/ -#include +#include //may define QT_NO_OPENSSL. krazy:exclude=includes #ifndef QT_NO_OPENSSL #include "KDSoapSslHandler.h" -#include KDSoapSslHandler::KDSoapSslHandler(QObject *parent) : QObject(parent), m_reply(0) diff --git a/src/KDSoapClient/KDSoapSslHandler.h b/src/KDSoapClient/KDSoapSslHandler.h index 1b85f3e49..1e6316740 100644 --- a/src/KDSoapClient/KDSoapSslHandler.h +++ b/src/KDSoapClient/KDSoapSslHandler.h @@ -102,7 +102,7 @@ public Q_SLOTS: explicit KDSoapSslHandler(QObject *parent = 0); virtual ~KDSoapSslHandler(); - QNetworkReply* m_reply; // could be replaced with a d pointer if needed + QNetworkReply* m_reply; }; #if QT_VERSION < 0x050000 diff --git a/src/KDSoapClient/KDSoapValue.h b/src/KDSoapClient/KDSoapValue.h index a927a7ccf..430f52ebe 100644 --- a/src/KDSoapClient/KDSoapValue.h +++ b/src/KDSoapClient/KDSoapValue.h @@ -270,7 +270,7 @@ namespace std { * In other words, it corresponds to a list of XML elements in a SOAP * message. It also supports XML attributes. */ -class KDSOAP_EXPORT KDSoapValueList : public QList +class KDSOAP_EXPORT KDSoapValueList : public QList //krazy:exclude=dpointer { public: /** diff --git a/src/KDSoapServer/KDSoapServerSocket.cpp b/src/KDSoapServer/KDSoapServerSocket.cpp index eb47c84ec..37c7b38fc 100644 --- a/src/KDSoapServer/KDSoapServerSocket.cpp +++ b/src/KDSoapServer/KDSoapServerSocket.cpp @@ -238,19 +238,19 @@ void KDSoapServerSocket::slotReadyRead() // check soap version and extract soapAction header QByteArray soapAction; const QByteArray contentType = httpHeaders.value("content-type"); - if (contentType.startsWith("text/xml")) { + if (contentType.startsWith("text/xml")) { //krazy:exclude=strings // SOAP 1.1 soapAction = httpHeaders.value("soapaction"); // The SOAP standard allows quotation marks around the SoapAction, so we have to get rid of these. if (soapAction.startsWith('\"')) soapAction = soapAction.mid(1, soapAction.length() - 2); - } else if (contentType.startsWith("application/soap+xml")) { + } else if (contentType.startsWith("application/soap+xml")) { //krazy:exclude=strings // SOAP 1.2 // Example: application/soap+xml;charset=utf-8;action=ActionHex const QList parts = contentType.split(';'); Q_FOREACH(const QByteArray& part, parts) { - if (part.startsWith("action=")) { + if (part.startsWith("action=")) { //krazy:exclude=strings soapAction = part.mid(strlen("action=")); } } diff --git a/unittests/builtinhttp/builtinhttp.cpp b/unittests/builtinhttp/builtinhttp.cpp index c4ef912a5..7796a8201 100644 --- a/unittests/builtinhttp/builtinhttp.cpp +++ b/unittests/builtinhttp/builtinhttp.cpp @@ -236,7 +236,7 @@ private Q_SLOTS: HttpServerThread server(emptyResponse(), HttpServerThread::Public); KDSoapClientInterface client(server.endPoint(), countryMessageNamespace()); KDSoapMessage message; - message.setUse(KDSoapMessage::EncodedUse); // write out types explicitely + message.setUse(KDSoapMessage::EncodedUse); // write out types explicitly // Test simpletype element message.addArgument(QString::fromLatin1("testString"), QString::fromUtf8("Hello Klarälvdalens")); diff --git a/unittests/specialchars_wsdl/testconversion.cpp b/unittests/specialchars_wsdl/testconversion.cpp index 1d5169c42..12a6a6cd3 100644 --- a/unittests/specialchars_wsdl/testconversion.cpp +++ b/unittests/specialchars_wsdl/testconversion.cpp @@ -39,7 +39,7 @@ private slots: TestConversion::TestConversion() { - + } @@ -51,4 +51,4 @@ void TestConversion::test() QTEST_MAIN(TestConversion) -#include "testconversion.moc" \ No newline at end of file +#include "testconversion.moc" diff --git a/unittests/wsdl_document/test_wsdl_document.cpp b/unittests/wsdl_document/test_wsdl_document.cpp index 91100c779..3ff700de4 100644 --- a/unittests/wsdl_document/test_wsdl_document.cpp +++ b/unittests/wsdl_document/test_wsdl_document.cpp @@ -224,7 +224,7 @@ private Q_SLOTS: MyWsdlDocument service; service.setEndPoint(server.endPoint()); QVERIFY(server.endPoint().startsWith(QLatin1String("https"))); - QSignalSpy sslErrorsSpy(service.clientInterface()->sslHandler(), SIGNAL(sslErrors(KDSoapSslHandler*, QList))); + QSignalSpy sslErrorsSpy(service.clientInterface()->sslHandler(), SIGNAL(sslErrors(KDSoapSslHandler*,QList))); // We need to use async API to test sslHandler, see documentation there. ListEmployeesJob *job = new ListEmployeesJob(&service); connect(job, SIGNAL(finished(KDSoapJob*)), this, SLOT(slotListEmployeesJobFinished(KDSoapJob*))); @@ -252,8 +252,8 @@ private Q_SLOTS: HttpServerThread server(addEmployeeResponse(), HttpServerThread::Ssl); MyWsdlDocument service; service.setEndPoint(server.endPoint()); - connect(service.clientInterface()->sslHandler(), SIGNAL(sslErrors(KDSoapSslHandler*, QList)), - this, SLOT(slotSslHandlerErrors(KDSoapSslHandler*, QList))); + connect(service.clientInterface()->sslHandler(), SIGNAL(sslErrors(KDSoapSslHandler*,QList)), + this, SLOT(slotSslHandlerErrors(KDSoapSslHandler*,QList))); AddEmployeeJob *job = new AddEmployeeJob(&service); job->setParameters(addEmployeeParameters()); connect(job, SIGNAL(finished(KDSoapJob*)), this, SLOT(slotAddEmployeeJobFinished(KDSoapJob*))); @@ -304,7 +304,7 @@ private Q_SLOTS: HttpServerThread server(addEmployeeResponse(), HttpServerThread::Ssl); MyWsdlDocument service; service.setEndPoint(server.endPoint()); - QSignalSpy sslErrorsSpy(service.clientInterface()->sslHandler(), SIGNAL(sslErrors(KDSoapSslHandler*, QList))); + QSignalSpy sslErrorsSpy(service.clientInterface()->sslHandler(), SIGNAL(sslErrors(KDSoapSslHandler*,QList))); QByteArray ret = service.addEmployee(addEmployeeParameters()); QVERIFY(ret.isEmpty()); QVERIFY2(service.lastError().contains(QLatin1String("SSL handshake failed")), qPrintable(service.lastError())); @@ -943,10 +943,10 @@ void WsdlDocumentTest::testServerFault() // test the error signals emitted on er MyWsdlDocument service; service.setEndPoint(server->endPoint()); QSignalSpy addEmployeeErrorSpy(&service, SIGNAL(addEmployeeError(KDSoapMessage))); - QSignalSpy soapErrorSpy(&service, SIGNAL(soapError(QString, KDSoapMessage))); + QSignalSpy soapErrorSpy(&service, SIGNAL(soapError(QString,KDSoapMessage))); service.asyncAddEmployee(KDAB__AddEmployee()); - connect(&service, SIGNAL(soapError(QString, KDSoapMessage)), &m_eventLoop, SLOT(quit())); + connect(&service, SIGNAL(soapError(QString,KDSoapMessage)), &m_eventLoop, SLOT(quit())); m_eventLoop.exec(); QCOMPARE(soapErrorSpy.count(), 1);