ipc: Avoid 'unistd.h' error with MSVC

Avoid compile error from MSVC:

D:\a\bitcoin\bitcoin\src\ipc\interfaces.cpp(24,1): error C1083: Cannot open include file: 'unistd.h': No such file or directory

MinGW provides this header but MSVC does not. Header is unneeded on windows
because HandleCtrlC code that uses it is not compiled on windows.
This commit is contained in:
Ryan Ofsky
2026-06-21 20:47:58 -04:00
parent dbcc192dce
commit 3449797141

View File

@@ -21,10 +21,13 @@
#include <memory>
#include <stdexcept>
#include <string>
#include <unistd.h>
#include <utility>
#include <vector>
#ifndef WIN32
#include <unistd.h>
#endif
namespace ipc {
namespace {
#ifndef WIN32