diff options
Diffstat (limited to 'test/ipc/unixsocket_ipc.cpp')
-rw-r--r-- | test/ipc/unixsocket_ipc.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/test/ipc/unixsocket_ipc.cpp b/test/ipc/unixsocket_ipc.cpp index 1a8d06a1..3ee6017e 100644 --- a/test/ipc/unixsocket_ipc.cpp +++ b/test/ipc/unixsocket_ipc.cpp @@ -49,9 +49,9 @@ public: ipc_.readyRead.connect(this, &UnixSocketTestIPCSlave::readyRead); } - int run(int fd) + int run(UniqueFD fd) { - if (ipc_.bind(fd)) { + if (ipc_.bind(std::move(fd))) { cerr << "Failed to connect to IPC channel" << endl; return EXIT_FAILURE; } @@ -222,9 +222,9 @@ int main(int argc, char **argv) { /* IPCPipeUnixSocket passes IPA module path in argv[1] */ if (argc == 3) { - int ipcfd = std::stoi(argv[2]); + UniqueFD ipcfd = UniqueFD(std::stoi(argv[2])); UnixSocketTestIPCSlave slave; - return slave.run(ipcfd); + return slave.run(std::move(ipcfd)); } UnixSocketTestIPC test; |