[frameworks/kdav] /: davmanager: Add missing doctype to sent XML

Kevin Ottens <[email protected]>
Newsgroups gmane.comp.kde.cvs
Message-ID <[email protected]>
Git commit 2bf3989415e8b8fd155adadbc811c65249b388a7 by Kevin Ottens, on behalf of Carl Schwan.
Committed on 28/07/2026 at 19:47.
Pushed by ervin into branch 'master'.

davmanager: Add missing doctype to sent XML

This was done in KIO::DavJob previously and adapt CI configuration for
the reduced dependencies chain.

M  +1    -0    .gitlab-ci.yml
M  +2    -1    .kde-ci.yml
M  +0    -3    autotests/fakeserver.cpp
M  +1    -1    src/common/davmanager.cpp

https://invent.kde.org/frameworks/kdav/-/commit/2bf3989415e8b8fd155adadbc811c65249b388a7

diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index 660374f..b9b6192 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -6,6 +6,7 @@ include:
     file:
       - /gitlab-templates/linux-qt6.yml
       - /gitlab-templates/linux-qt6-next.yml
+      - /gitlab-templates/alpine-qt6.yml
       - /gitlab-templates/android-qt6.yml
       - /gitlab-templates/freebsd-qt6.yml
       - /gitlab-templates/windows-qt6.yml
diff --git a/.kde-ci.yml b/.kde-ci.yml
index 6ef0abb..910e052 100644
--- a/.kde-ci.yml
+++ b/.kde-ci.yml
@@ -2,7 +2,8 @@ Dependencies:
  - 'on': ['@all']
    'require':
     'frameworks/extra-cmake-modules': '@same'
-    'frameworks/kio': '@same'
+    'frameworks/ki18n': '@same'
+    'frameworks/kcoreaddons': '@same'
 
 Options:
  test-before-installing: True
diff --git a/autotests/fakeserver.cpp b/autotests/fakeserver.cpp
index d622275..dbd06e5 100644
--- a/autotests/fakeserver.cpp
+++ b/autotests/fakeserver.cpp
@@ -210,9 +210,6 @@ void FakeServer::readClientPart(QTcpSocket *socket, int *scenarioNumber)
         line = socket->readLine();
     }
 
-    // read content
-    socket->readAll();
-
     while (!scenario.isEmpty() && scenario.first().startsWith("C: ")) {
         QByteArray expected = scenario.takeFirst().mid(3) + "\r\n";
 
diff --git a/src/common/davmanager.cpp b/src/common/davmanager.cpp
index 210a342..6b0e1c6 100644
--- a/src/common/davmanager.cpp
+++ b/src/common/davmanager.cpp
@@ -75,7 +75,7 @@ QNetworkReply *DavManager::sendDavRequest(const QByteArray &method, const QUrl &
         request.setRawHeader("Depth", depth.toUtf8());
     }
     request.setHeader(QNetworkRequest::UserAgentHeader, userAgent());
-    return mNam->sendCustomRequest(request, method, document.toUtf8());
+    return mNam->sendCustomRequest(request, method, QByteArray("<?xml version=\"1.0\" encoding=\"utf-8\"?>\n") + document.toUtf8());
 }
 
 const DavProtocolBase *DavManager::davProtocol(Protocol protocol)
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.