RCU lf queue: Add assert for memory allocation
authorMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Fri, 1 Jul 2011 21:06:16 +0000 (17:06 -0400)
committerMathieu Desnoyers <mathieu.desnoyers@efficios.com>
Fri, 1 Jul 2011 21:06:16 +0000 (17:06 -0400)
Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
urcu/static/rculfqueue.h

index b83862f26c21c400484aa8f43f4c39c0516ba709..0b83bc37ffb2c5b0e3b19218299286e571d70580 100644 (file)
@@ -79,6 +79,7 @@ struct cds_lfq_node_rcu *make_dummy(struct cds_lfq_queue_rcu *q,
        struct cds_lfq_node_rcu_dummy *dummy;
 
        dummy = malloc(sizeof(struct cds_lfq_node_rcu_dummy));
+       assert(dummy);
        dummy->parent.next = next;
        dummy->q = q;
        return (struct cds_lfq_node_rcu *) (((unsigned long) &dummy->parent) | 0x1UL);
This page took 0.027075 seconds and 4 git commands to generate.