X-Git-Url: https://git.m6w6.name/?a=blobdiff_plain;f=test%2Flib%2FServer.hpp;h=26acdc4468b2f89ff0b4524e28ea3251a273a923;hb=cfd4a0cf233411410d297a7a0965ff88fffe87b0;hp=5e263267b1cdd252d61180d9d8808fe0c3061701;hpb=fb3710011600c04359d26615be7a92df1742a3e9;p=awesomized%2Flibmemcached diff --git a/test/lib/Server.hpp b/test/lib/Server.hpp index 5e263267..26acdc44 100644 --- a/test/lib/Server.hpp +++ b/test/lib/Server.hpp @@ -36,8 +36,10 @@ public: Server(const Server &s); Server &operator=(const Server &s); - Server(Server &&s) { *this = move(s); }; - Server &operator=(Server &&s) { + Server(Server &&s) noexcept { + *this = move(s); + }; + Server &operator=(Server &&s) noexcept { binary = exchange(s.binary, "false"); args = exchange(s.args, {}); pid = exchange(s.pid, 0); @@ -67,7 +69,7 @@ public: bool signal(int signo = SIGTERM); bool check(); - bool isListening(); + bool isListening() const; bool ensureListening(); bool wait(int flags = 0); @@ -89,7 +91,7 @@ private: optional handleArg(vector &arr, const string &arg, const arg_func_t &next_arg); }; -inline ostream &operator<<(ostream &out, const socket_or_port_t sop) { +inline ostream &operator<<(ostream &out, const socket_or_port_t &sop) { if (holds_alternative(sop)) { out << get(sop); } else {