Automatically free the request once the callback has returned.
authorRonnie Sahlberg <ronniesahlberg@gmail.com>
Wed, 2 Jun 2010 03:42:03 +0000 (13:42 +1000)
committerRonnie Sahlberg <ronniesahlberg@gmail.com>
Wed, 2 Jun 2010 03:42:03 +0000 (13:42 +1000)
libctdb/ctdb.c

index c9adfdaa2ce28185d88e9d355fc92b5e10e114f8..08355efbd1b5c9c60a3165a67b5c9697fe465b22 100644 (file)
@@ -240,6 +240,7 @@ static void handle_incoming(struct ctdb_connection *ctdb, struct io_elem *in)
                        DLIST_REMOVE(ctdb->doneq, i);
                        i->reply = in;
                        i->callback(ctdb, i, i->priv_data);
+                       ctdb_request_free(i);
                        return;
                }
        }