p9y: fix includes
[m6w6/libmemcached] / test / lib / Connection.cpp
index b6df553b1ca5f166c259cb29118b6e2ded18b036..82414f135127d373588e37b67846365e3b599a2b 100644 (file)
@@ -1,8 +1,10 @@
 #include "Connection.hpp"
+#include "p9y/poll.hpp"
 
 #include <cerrno>
-#include <sys/poll.h>
-#include <unistd.h>
+#if HAVE_UNISTD_H
+#  include <unistd.h>
+#endif
 
 #if !(HAVE_SOCK_NONBLOCK && HAVE_SOCK_CLOEXEC)
 #  include <fcntl.h>
@@ -193,6 +195,5 @@ string Connection::error(const initializer_list<string> &args) {
     ss << arg;
   }
 
-  cerr << ss.str() << endl;
   return ss.str();
 }