Revision: 3167 http://trac.macosforge.org/projects/ruby/changeset/3167 Author: ernest.prabhakar@gmail.com Date: 2009-12-23 14:00:50 -0800 (Wed, 23 Dec 2009) Log Message: ----------- Added asserts to gcd.c Modified Paths: -------------- MacRuby/trunk/gcd.c Modified: MacRuby/trunk/gcd.c =================================================================== --- MacRuby/trunk/gcd.c 2009-12-23 21:42:21 UTC (rev 3166) +++ MacRuby/trunk/gcd.c 2009-12-23 22:00:50 UTC (rev 3167) @@ -310,6 +310,7 @@ queue->suspension_count = 0; queue->should_release_queue = 1; queue->queue = dispatch_queue_create(RSTRING_PTR(name), NULL); + assert(queue->queue != NULL) dispatch_retain(queue->queue); return self; } @@ -606,6 +607,8 @@ rb_group_initialize(VALUE self, SEL sel) { RGroup(self)->group = dispatch_group_create(); + assert(RGroup(self)->group != NULL); + return self; } @@ -751,6 +754,7 @@ src->type = rb_num2source_type(type); src->source = dispatch_source_create(src->type, NUM2UINT(handle), NUM2LONG(mask), RQueue(queue)->queue); + assert(src->source != NULL); if (rb_block_given_p()) { rb_source_on_event(self, 0);
participants (1)
-
source_changes@macosforge.org