From 3be6d105252d2153a6c05a4e788f615ed0921d6b Mon Sep 17 00:00:00 2001 From: Alex Beregszaszi Date: Tue, 7 Feb 2017 12:32:58 +0000 Subject: Avoid crash if fdopen failed in IPC --- test/RPCSession.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/test/RPCSession.cpp b/test/RPCSession.cpp index f67696d9..43f10824 100644 --- a/test/RPCSession.cpp +++ b/test/RPCSession.cpp @@ -75,6 +75,8 @@ IPCSocket::IPCSocket(string const& _path): m_path(_path) BOOST_FAIL("Error connecting to IPC socket: " << _path); m_fp = fdopen(m_socket, "r"); + if (!m_fp) + BOOST_FAIL("Error opening IPC socket: " << _path); #endif } -- cgit