Actually, use this patch.. it fixes an additional use-after-free.

Index: RdmaServer.cpp
===================================================================
--- RdmaServer.cpp      (revision 1004875)
+++ RdmaServer.cpp      (working copy)
@@ -118,18 +118,18 @@
     ConRec* cr = ci->getContext<ConRec>();
     cr->connection->disconnect();
     cr->data->drainWriteQueue(drained);
+    cout << "Disconnected: " << cr << "\n";
     delete cr;
-    cout << "Disconnected: " << cr << "\n";
 }

 void connectionError(Rdma::Connection::intrusive_ptr& ci, Rdma::ErrorType) {
     ConRec* cr = ci->getContext<ConRec>();
-    cr->connection->disconnect();
     if (cr) {
-        cr->data->drainWriteQueue(drained);
-        delete cr;
+       cr->connection->disconnect();
+       cr->data->drainWriteQueue(drained);
+       cout << "Connection error: " << cr << "\n";
+       delete cr;
     }
-    cout << "Connection error: " << cr << "\n";
 }

---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:[email protected]

Reply via email to