wsd: clean up unused header includes

Clang-tidy recommendation driven header
include clean-up.

Change-Id: I30c32866b7798e70df0463ee6bc7a0bcc3de5049
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
pull/7973/head
Ashod Nakashian 2024-01-05 02:16:13 -05:00 committed by Miklos Vajna
parent 4dc2cd4e16
commit 61cf7b9601
54 changed files with 45 additions and 127 deletions

View File

@ -14,6 +14,8 @@
#include "MessageQueue.hpp"
#include <climits>
#include <algorithm>
#include <string>
#include <string_view>
#include <iostream>
#include <Poco/JSON/JSON.h>

View File

@ -13,10 +13,10 @@
#include "Protocol.hpp"
#include <cassert>
#include <cstring>
#include <map>
#include <string>
#include <string_view>
#define LOK_USE_UNSTABLE_API
#include <LibreOfficeKit/LibreOfficeKitEnums.h>

View File

@ -11,20 +11,17 @@
#pragma once
#include <StringVector.hpp>
#include <Util.hpp>
#include <cstdint>
#include <cstdlib>
#include <cstring>
#include <iomanip>
#include <map>
#include <regex>
#include <sstream>
#include <string>
#include <string_view>
#include <vector>
#include <StringVector.hpp>
#include <Util.hpp>
#define LOK_USE_UNSTABLE_API
#include <LibreOfficeKit/LibreOfficeKitEnums.h>

View File

@ -10,6 +10,7 @@
#include <cstdint>
#include <cstring>
#include <string>
#include <string_view>
#include <utility>
#include <vector>

View File

@ -16,17 +16,13 @@
#include <Poco/MemoryStream.h>
#include <Poco/Net/HTTPResponse.h>
#include <chrono>
#include <cstdint>
#include <fstream>
#include <memory>
#include <sstream>
#include <stdexcept>
#include <string>
#include <sys/types.h>
#include <netdb.h>
#include "Common.hpp"
#include <utility>
#include "Log.hpp"
#include "Util.hpp"

View File

@ -12,6 +12,7 @@
#include <config.h>
#include "Socket.hpp"
#include "TraceEvent.hpp"
#include "Util.hpp"
#include <cstring>

View File

@ -22,26 +22,24 @@
#include <cassert>
#include <cerrno>
#include <chrono>
#include <climits>
#include <cstdlib>
#include <cstring>
#include <fstream>
#include <functional>
#include <iostream>
#include <memory>
#include <mutex>
#include <sstream>
#include <thread>
#include "Common.hpp"
#include <common/StateEnum.hpp>
#include "FakeSocket.hpp"
#include "Log.hpp"
#include "Util.hpp"
#include "Protocol.hpp"
#include "Buffer.hpp"
#include "SigUtil.hpp"
#if MOBILEAPP
#include "FakeSocket.hpp"
#endif
#ifdef __linux__
#define HAVE_ABSTRACT_UNIX_SOCKETS
#endif

View File

@ -11,7 +11,6 @@
#include <config.h>
#include <assert.h>
#include <unistd.h>
#include "Ssl.hpp"

View File

@ -13,12 +13,9 @@
#include <common/Util.hpp>
#include <atomic>
#include <cassert>
#include <memory>
#include <mutex>
#include <string>
#include <vector>
#include <openssl/ssl.h>
#include <openssl/rand.h>

View File

@ -11,15 +11,14 @@
#pragma once
#include "Ssl.hpp"
#include "Socket.hpp"
#include <cerrno>
#include <memory>
#include <sstream>
#include <string>
#include "Common.hpp"
#include "Ssl.hpp"
#include "Socket.hpp"
/// An SSL/TSL, non-blocking, data streaming socket.
class SslStreamSocket final : public StreamSocket
{

View File

@ -11,13 +11,9 @@
#pragma once
#include <chrono>
#include <memory>
#include <vector>
#include "common/Protocol.hpp"
#include "common/Common.hpp"
#include "common/Log.hpp"
#include "common/TraceEvent.hpp"
#include "common/Unit.hpp"
#include "common/Util.hpp"
#include "Socket.hpp"
@ -28,6 +24,10 @@
#include <Poco/Net/HTTPResponse.h>
#include <Poco/Net/WebSocket.h>
#include <chrono>
#include <memory>
#include <vector>
class WebSocketHandler : public ProtocolHandlerInterface
{
private:

View File

@ -14,21 +14,17 @@
#include <chrono>
#include <cstdint>
#include <iostream>
#include <fstream>
#include <memory>
#include <condition_variable>
#include <mutex>
#include <sstream>
#include <string>
#include "Common.hpp"
#include <common/MessageQueue.hpp>
#include "NetUtil.hpp"
#include "SigUtil.hpp"
#include <net/Socket.hpp>
#include <net/HttpRequest.hpp>
#include <net/WebSocketHandler.hpp>
#include <utility>
#if ENABLE_SSL
#include <net/SslSocket.hpp>
#endif

View File

@ -11,12 +11,9 @@
#include <config.h>
#include <atomic>
#include <cerrno>
#include <cstdlib>
#include <cstring>
#include <iostream>
#include <mutex>
#include <thread>
#include <assert.h>
@ -39,12 +36,10 @@
#include <Util.hpp>
using Poco::Net::HTTPClientSession;
using Poco::Runnable;
using Poco::Net::HTTPRequest;
using Poco::Net::HTTPResponse;
using Poco::Net::WebSocket;
using Poco::Runnable;
using Poco::Util::Application;
const char *HostName = "127.0.0.1";
constexpr int HttpPortNumber = 9191;

View File

@ -13,7 +13,6 @@
#include <memory>
#include <ostream>
#include <set>
#include <string>
#include <Poco/Exception.h>

View File

@ -13,7 +13,6 @@
#include <chrono>
#include <memory>
#include <ostream>
#include <string>
#include <Poco/Exception.h>

View File

@ -11,9 +11,7 @@
#include <config.h>
#include <cassert>
#include <iostream>
#include <random>
#include <Common.hpp>
#include <Protocol.hpp>

View File

@ -12,8 +12,6 @@
#include <config.h>
#include <memory>
#include <ostream>
#include <set>
#include <string>
#include <Poco/Exception.h>

View File

@ -11,7 +11,6 @@
#include <config.h>
#include <cassert>
#include <iostream>
#include <random>

View File

@ -11,8 +11,6 @@
#include <config.h>
#include <cassert>
#include <helpers.hpp>
#include <Poco/Util/Application.h>
#include <Poco/Net/StreamSocket.h>

View File

@ -11,7 +11,6 @@
#pragma once
#include <memory>
#include <sstream>
#include <Poco/Net/HTTPClientSession.h>

View File

@ -14,8 +14,6 @@
#include <net/HttpRequest.hpp>
#include <memory>
#include <ostream>
#include <set>
#include <string>
#include <Poco/DOM/AutoPtr.h>

View File

@ -14,7 +14,6 @@
#include <memory>
#include <ostream>
#include <set>
#include <string>
#include <Poco/Exception.h>

View File

@ -20,9 +20,7 @@
#include <chrono>
#include <memory>
#include <ostream>
#include <set>
#include <string>
#include <thread>
#include <Poco/Exception.h>
#include <Poco/URI.h>

View File

@ -13,10 +13,7 @@
#include "WopiTestServer.hpp"
#include "WOPIUploadConflictCommon.hpp"
#include "Log.hpp"
#include "Unit.hpp"
#include "UnitHTTP.hpp"
#include "helpers.hpp"
#include "lokassert.hpp"
#include "testlog.hpp"
#include "FileUtil.hpp"

View File

@ -13,13 +13,11 @@
#include <chrono>
#include <cassert>
#include <sysexits.h>
#include <Log.hpp>
#include <Util.hpp>
#include <Unit.hpp>
#include "lokassert.hpp"
class UnitTimeout : public UnitWSD
{

View File

@ -12,7 +12,6 @@
#include <config.h>
#include "HttpRequest.hpp"
#include "Util.hpp"
#include "lokassert.hpp"
#include <WopiTestServer.hpp>

View File

@ -18,10 +18,6 @@
#include <Poco/Net/HTTPRequest.h>
#include "Util.hpp"
#include "Log.hpp"
#include "UnitHTTP.hpp"
#include "helpers.hpp"
#include "lokassert.hpp"
class UnitWOPIDocumentConflict : public WOPIUploadConflictCommon

View File

@ -21,8 +21,6 @@
#include "Util.hpp"
#include "Log.hpp"
#include "UnitHTTP.hpp"
#include "helpers.hpp"
#include "lokassert.hpp"
/// This test simulates a permanently-failing upload.

View File

@ -12,7 +12,6 @@
#include <config.h>
#include "Unit.hpp"
#include "lokassert.hpp"
#include <WopiTestServer.hpp>
#include <Log.hpp>

View File

@ -12,7 +12,6 @@
#include <config.h>
#include "HttpRequest.hpp"
#include "Util.hpp"
#include "lokassert.hpp"
#include <WopiTestServer.hpp>

View File

@ -12,10 +12,7 @@
#include "config.h"
#include "WopiTestServer.hpp"
#include "Log.hpp"
#include "Unit.hpp"
#include "UnitHTTP.hpp"
#include "helpers.hpp"
#include "lokassert.hpp"
#include <Poco/Net/HTTPRequest.h>

View File

@ -12,10 +12,7 @@
#include "config.h"
#include "WopiTestServer.hpp"
#include "Log.hpp"
#include "Unit.hpp"
#include "UnitHTTP.hpp"
#include "helpers.hpp"
#include "lokassert.hpp"
#include <Poco/Net/HTTPRequest.h>

View File

@ -12,7 +12,6 @@
#pragma once
#include <string>
#include <memory>
#include <Poco/Net/HTTPRequest.h>

View File

@ -23,8 +23,9 @@
#include <Common.hpp>
#include "Util.hpp"
#include "lokassert.hpp"
#include "test.hpp"
#include "helpers.hpp"
#include "testlog.hpp"
static int countCoolKitProcesses(const int expected,
std::chrono::milliseconds timeoutMs

View File

@ -11,6 +11,7 @@
#pragma once
#include <ctime>
#include <set>
/// Are we running inside WSD or by ourselves.

View File

@ -13,16 +13,14 @@
#include <test/testlog.hpp>
#include <cstdlib>
#include <mutex>
#include <thread>
#include <Poco/Net/WebSocket.h>
#include <Common.hpp>
#include <Protocol.hpp>
#include <Log.hpp>
#include <iomanip>
/// Deprecated: do not use ... replaced by net/Socket.hpp
///
/// WebSocket that is thread safe, and handles large frames transparently.

View File

@ -12,6 +12,7 @@
#pragma once
#include <math.h>
#include <iomanip>
#include <chrono>
#include <cstring>
#include <unordered_map>

View File

@ -9,10 +9,10 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
#include <chrono>
#include <config.h>
#include <cassert>
#include <chrono>
#include <iomanip>
#include <sys/poll.h>
#include <unistd.h>
@ -24,11 +24,8 @@
#include "AdminModel.hpp"
#include "Auth.hpp"
#include <Common.hpp>
#include "FileServer.hpp"
#include <Log.hpp>
#include <Protocol.hpp>
#include "Storage.hpp"
#include "TileCache.hpp"
#include <StringVector.hpp>
#include <Unit.hpp>
#include <Util.hpp>

View File

@ -12,7 +12,6 @@
#pragma once
#include "AdminModel.hpp"
#include "Log.hpp"
#include "net/WebSocketHandler.hpp"
#include "COOLWSD.hpp"

View File

@ -14,6 +14,7 @@
#include "AdminModel.hpp"
#include <chrono>
#include <cmath>
#include <memory>
#include <set>
#include <sstream>

View File

@ -11,17 +11,16 @@
#pragma once
#include <cmath>
#include <ctime>
#include <list>
#include <memory>
#include <regex>
#include <set>
#include <string>
#include <utility>
#include <Poco/URI.h>
#include <common/Log.hpp>
#include "Util.hpp"
#include "net/WebSocketHandler.hpp"
struct DocumentAggregateStats;

View File

@ -13,7 +13,6 @@
#pragma once
#include <cassert>
#include <string>
#include <memory>

View File

@ -31,7 +31,6 @@
#include "Util.hpp"
#include "FileUtil.hpp"
#include "RequestDetails.hpp"
#include "WebSocketHandler.hpp"
#include "QuarantineUtil.hpp"

View File

@ -13,9 +13,10 @@
#include "ClientSession.hpp"
#include <fstream>
#include <ios>
#include <sstream>
#include <string>
#include <string_view>
#include <memory>
#include <unordered_map>

View File

@ -13,15 +13,12 @@
#include "Session.hpp"
#include "Storage.hpp"
#include "MessageQueue.hpp"
#include "SenderQueue.hpp"
#include "ServerURL.hpp"
#include "DocumentBroker.hpp"
#include <Poco/URI.h>
#include <Rectangle.hpp>
#include <deque>
#include <map>
#include <list>
#include <utility>
#include "Util.hpp"

View File

@ -34,12 +34,11 @@
#include "Admin.hpp"
#include "ClientSession.hpp"
#include "Exceptions.hpp"
#include "JailUtil.hpp"
#include "COOLWSD.hpp"
#include "SenderQueue.hpp"
#include "Socket.hpp"
#include "Storage.hpp"
#include "TileCache.hpp"
#include "TraceEvent.hpp"
#include "ProxyProtocol.hpp"
#include "Util.hpp"
#include "QuarantineUtil.hpp"

View File

@ -11,19 +11,14 @@
#pragma once
#include <csignal>
#include <atomic>
#include <chrono>
#include <condition_variable>
#include <cstddef>
#include <deque>
#include <map>
#include <memory>
#include <mutex>
#include <sstream>
#include <string>
#include <thread>
#include <utility>
#include <Poco/URI.h>

View File

@ -15,7 +15,6 @@
#pragma once
#include <atomic>
#include <exception>
#include <stdexcept>
#include <string>

View File

@ -11,20 +11,17 @@
#pragma once
#include <deque>
#include <memory>
#include <mutex>
#include <thread>
#include <vector>
#include "common/SigUtil.hpp"
#include "Log.hpp"
#include "TileDesc.hpp"
#include <Poco/Dynamic/Var.h>
#include <Poco/JSON/JSON.h>
#include <Poco/JSON/Object.h>
#include <Poco/JSON/Parser.h>
#include "common/SigUtil.hpp"
#include "Log.hpp"
#include "TileDesc.hpp"
#include <deque>
#include <mutex>
/// A queue of data to send to certain Session's WS.
template <typename Item>

View File

@ -14,7 +14,6 @@
#pragma once
#include <memory>
#include <set>
#include <string>
#include <chrono>
@ -22,7 +21,6 @@
#include <Poco/Util/Application.h>
#include <Poco/JSON/Object.h>
#include "Auth.hpp"
#include "HttpRequest.hpp"
#include "COOLWSD.hpp"
#include "Log.hpp"

View File

@ -8,17 +8,12 @@
#pragma once
#include <memory>
#include <set>
#include <string>
#include <chrono>
#include <Poco/URI.h>
#include <Poco/Util/Application.h>
#include "Authorization.hpp"
#include "COOLWSD.hpp"
#include "Log.hpp"
#include "Util.hpp"
/// A Storage Manager is responsible for the settings
/// of Storage and the creation of http::Session and

View File

@ -17,7 +17,7 @@
#include <climits>
#include <cstddef>
#include <cstdio>
#include <fstream>
#include <iomanip>
#include <iostream>
#include <memory>
#include <sstream>

View File

@ -11,15 +11,15 @@
#pragma once
#include <Exceptions.hpp>
#include <Protocol.hpp>
#include <StringVector.hpp>
#include <cassert>
#include <unordered_map>
#include <sstream>
#include <string>
#include "Exceptions.hpp"
#include <Protocol.hpp>
#include <StringVector.hpp>
#include <string_view>
#define TILE_WIRE_ID
using TileWireId = uint32_t;

View File

@ -5,11 +5,8 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
#include "COOLWSD.hpp"
#include "RequestDetails.hpp"
#include <Storage.hpp>
#include "WebSocketHandler.hpp"
#include <string>
#include <utility>