librdmacm: free event structure on failure
authorshefty <shefty@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Wed, 15 Jul 2009 21:53:54 +0000 (21:53 +0000)
committershefty <shefty@ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86>
Wed, 15 Jul 2009 21:53:54 +0000 (21:53 +0000)
Signed-off-by: Sean Hefty <sean.hefty@intel.com>
git-svn-id: svn://openib.tc.cornell.edu/gen1/trunk@2301 ad392aa1-c5ef-ae45-8dd8-e69d62a5ef86

ulp/librdmacm/src/cma.cpp

index 757e4cd..72411bd 100644 (file)
@@ -986,6 +986,7 @@ int rdma_get_cm_event(struct rdma_event_channel *channel,
 \r
                ret = CompChannelPoll(&channel->channel, &entry);\r
                if (ret) {\r
 \r
                ret = CompChannelPoll(&channel->channel, &entry);\r
                if (ret) {\r
+                       delete evt;\r
                        return ret;\r
                }\r
 \r
                        return ret;\r
                }\r
 \r