diff options
author | Timo Dritschler <timo.dritschler@kit.edu> | 2014-12-04 18:33:54 +0100 |
---|---|---|
committer | Timo Dritschler <timo.dritschler@kit.edu> | 2014-12-04 18:33:54 +0100 |
commit | b71e3e75e13a40838c1b386fdeff3afd2f453e9f (patch) | |
tree | 9b33ad848c79c66e8998e2d954978b72d3574737 | |
parent | cc2059982024af79136b9420eaec6fcfedabf3fb (diff) | |
download | kiro-b71e3e75e13a40838c1b386fdeff3afd2f453e9f.tar.gz kiro-b71e3e75e13a40838c1b386fdeff3afd2f453e9f.tar.bz2 kiro-b71e3e75e13a40838c1b386fdeff3afd2f453e9f.tar.xz kiro-b71e3e75e13a40838c1b386fdeff3afd2f453e9f.zip |
Fixed a race condition concerning message handling in kiro client
-rw-r--r-- | src/kiro-client.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/kiro-client.c b/src/kiro-client.c index bb2645c..084e4b8 100644 --- a/src/kiro-client.c +++ b/src/kiro-client.c @@ -197,6 +197,11 @@ process_rdma_event (GIOChannel *source, GIOCondition condition, gpointer data) return FALSE; } + // make sure the next incoming work completion causes an event on the + // receive completion channel. We will poll() the channels file descriptor + // for this in the kiro client main loop. + ibv_req_notify_cq (priv->conn->recv_cq, 0); + return TRUE; } @@ -249,11 +254,6 @@ kiro_client_connect (KiroClient *self, const char *address, const char *port) g_critical ("Endpoint creation failed: %s", strerror (errno)); return -1; } - // make sure the receive queue pushes an event onto its completion channel - // This is needed in order to see any events on the recv_cq on its - // respective completion_channel file descriptor. We will use this - // mechanismn in our main loop to poll for those events. - ibv_req_notify_cq (priv->conn->recv_cq, 0); g_debug ("Route to server resolved"); struct kiro_connection_context *ctx = (struct kiro_connection_context *)g_try_malloc (sizeof (struct kiro_connection_context)); |