Open obiltschnig opened 1 week ago
The commit that fixes this problem should also solve the problem that the
Poco::Net::ServiceNotFoundException
exception is thrown when creating a PollSet
with a Chinese username in Windows.
// TemporaryFile path contains Chinese characters
_pSockFile.reset(new TemporaryFile);
// SocketAddress throw ServiceNotFoundException
_pSocket.reset(new ServerSocket(SocketAddress(_pSockFile->path())));
PollSet uses and event fd to interrupt an ongoing
poll()
inwakeUp()
. On POSIX platforms this useseventfd()
and works fine. On Windows, a ServerSocket is created (either as Unix domain socket or TCP socket) instead. The problem is that when that event fd is signaled, the implementation attempts to receive from it. Which is not going to work as it's a ServerSocket. So this eventfd stays signaled forever, causing high CPU load as poll() always returns immediately.