diff options
author | Max Kellermann <max@musicpd.org> | 2019-04-03 21:26:16 +0200 |
---|---|---|
committer | Max Kellermann <max@musicpd.org> | 2019-04-03 21:26:16 +0200 |
commit | 38298e0cd88afdf311f9481434f2960f6a09287a (patch) | |
tree | c3218f6ed16a28ea4a4f2836d6d2ae03aa1bdd3a /src/client | |
parent | 1213d979f8f2895e689b05fb2c2f1e8581e9169f (diff) |
client/Internal: move client_domain to Domain.hxx
Diffstat (limited to 'src/client')
-rw-r--r-- | src/client/Client.cxx | 4 | ||||
-rw-r--r-- | src/client/Domain.cxx | 23 | ||||
-rw-r--r-- | src/client/Domain.hxx | 25 | ||||
-rw-r--r-- | src/client/Expire.cxx | 3 | ||||
-rw-r--r-- | src/client/Internal.hxx | 2 | ||||
-rw-r--r-- | src/client/New.cxx | 1 | ||||
-rw-r--r-- | src/client/Process.cxx | 1 |
7 files changed, 53 insertions, 6 deletions
diff --git a/src/client/Client.cxx b/src/client/Client.cxx index c141edf3c..2bb326bf8 100644 --- a/src/client/Client.cxx +++ b/src/client/Client.cxx @@ -17,14 +17,12 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ -#include "Internal.hxx" +#include "Client.hxx" #include "Partition.hxx" #include "Instance.hxx" #include "util/Domain.hxx" #include "config.h" -const Domain client_domain("client"); - Client::~Client() noexcept { if (FullyBufferedSocket::IsDefined()) diff --git a/src/client/Domain.cxx b/src/client/Domain.cxx new file mode 100644 index 000000000..7487cf1a1 --- /dev/null +++ b/src/client/Domain.cxx @@ -0,0 +1,23 @@ +/* + * Copyright 2003-2019 The Music Player Daemon Project + * http://www.musicpd.org + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + */ + +#include "Domain.hxx" +#include "util/Domain.hxx" + +const Domain client_domain("client"); diff --git a/src/client/Domain.hxx b/src/client/Domain.hxx new file mode 100644 index 000000000..6c050c835 --- /dev/null +++ b/src/client/Domain.hxx @@ -0,0 +1,25 @@ +/* + * Copyright 2003-2019 The Music Player Daemon Project + * http://www.musicpd.org + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2 of the License, or + * (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License along + * with this program; if not, write to the Free Software Foundation, Inc., + * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. + */ + +#ifndef MPD_CLIENT_DOMAIN_HXX +#define MPD_CLIENT_DOMAIN_HXX + +extern const class Domain client_domain; + +#endif diff --git a/src/client/Expire.cxx b/src/client/Expire.cxx index 32adf5d54..3f6e57f6e 100644 --- a/src/client/Expire.cxx +++ b/src/client/Expire.cxx @@ -17,7 +17,8 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ -#include "Internal.hxx" +#include "Client.hxx" +#include "Domain.hxx" #include "Log.hxx" void diff --git a/src/client/Internal.hxx b/src/client/Internal.hxx index f9555e0cf..ff05e2a79 100644 --- a/src/client/Internal.hxx +++ b/src/client/Internal.hxx @@ -27,8 +27,6 @@ static constexpr unsigned CLIENT_MAX_SUBSCRIPTIONS = 16; static constexpr unsigned CLIENT_MAX_MESSAGES = 64; -extern const class Domain client_domain; - extern std::chrono::steady_clock::duration client_timeout; extern size_t client_max_command_list_size; extern size_t client_max_output_buffer_size; diff --git a/src/client/New.cxx b/src/client/New.cxx index 6ee1eeedb..5c21d2a7c 100644 --- a/src/client/New.cxx +++ b/src/client/New.cxx @@ -19,6 +19,7 @@ #include "config.h" #include "Internal.hxx" +#include "Domain.hxx" #include "List.hxx" #include "Partition.hxx" #include "Instance.hxx" diff --git a/src/client/Process.cxx b/src/client/Process.cxx index 1f37d6a91..f0820918c 100644 --- a/src/client/Process.cxx +++ b/src/client/Process.cxx @@ -18,6 +18,7 @@ */ #include "Internal.hxx" +#include "Domain.hxx" #include "protocol/Result.hxx" #include "command/AllCommands.hxx" #include "Log.hxx" |