Added a comment about Ruby queue destruction

pull/6886/head
murgatroid99 9 years ago
parent 9acc40f9b6
commit 5756c6862b
  1. 4
      src/ruby/ext/grpc/rb_completion_queue.c

@ -72,6 +72,10 @@ static void *grpc_rb_completion_queue_pluck_no_gil(void *param) {
/* Helper function to free a completion queue. */
void grpc_rb_completion_queue_destroy(grpc_completion_queue *cq) {
/* Every function that adds an event to a queue also synchronously plucks
that event from the queue, and holds a reference to the Ruby object that
holds the queue, so we only get to this point if all of those functions
have completed, and the queue is empty */
grpc_completion_queue_shutdown(cq);
grpc_completion_queue_destroy(cq);
}

Loading…
Cancel
Save