From 880e36df2657be2166a97e360d3192b8921e5b9d Mon Sep 17 00:00:00 2001 From: Matej Sekoranja Date: Thu, 6 Sep 2012 09:19:02 +0200 Subject: [PATCH] request connect fix --- TODO | 3 --- pvAccessApp/remoteClient/clientContextImpl.cpp | 5 ++++- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/TODO b/TODO index c905822..8825856 100644 --- a/TODO +++ b/TODO @@ -5,9 +5,6 @@ readSize checks if size is in limits of size_t? -1. protected void destroy(boolean createRequestFailed) { - - // should be called without any lock hold // TODO in Java as in C++ ? reportChannelStateChange(); diff --git a/pvAccessApp/remoteClient/clientContextImpl.cpp b/pvAccessApp/remoteClient/clientContextImpl.cpp index eb0b7fe..f9da6fa 100644 --- a/pvAccessApp/remoteClient/clientContextImpl.cpp +++ b/pvAccessApp/remoteClient/clientContextImpl.cpp @@ -3645,7 +3645,10 @@ namespace epics { if (m_connectionState == DESTROYED) throw std::runtime_error("Channel destroyed."); - return m_transport; + else if (m_connectionState == CONNECTED) + return m_transport; + else + return Transport::shared_pointer(); } virtual Transport::shared_pointer getTransport()