about summary refs log tree commit homepage
path: root/ext/posix_mq/posix_mq.c
diff options
context:
space:
mode:
authorEric Wong <normalperson@yhbt.net>2010-01-08 11:25:06 -0800
committerEric Wong <normalperson@yhbt.net>2010-01-08 11:26:10 -0800
commitd03c76ae11ca6294e05262df747e4d43822ada73 (patch)
treeb319c608278bc84813196ce401a5d146824ab3ee /ext/posix_mq/posix_mq.c
parentb3c31cf444e2ca3dae0f6d2370944bfbf3382d88 (diff)
downloadruby_posix_mq-d03c76ae11ca6294e05262df747e4d43822ada73.tar.gz
Most used open modes are well under INT_MAX, however
Diffstat (limited to 'ext/posix_mq/posix_mq.c')
-rw-r--r--ext/posix_mq/posix_mq.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/posix_mq/posix_mq.c b/ext/posix_mq/posix_mq.c
index ca0cab8..3972620 100644
--- a/ext/posix_mq/posix_mq.c
+++ b/ext/posix_mq/posix_mq.c
@@ -331,7 +331,7 @@ static VALUE init(int argc, VALUE *argv, VALUE self)
         switch (TYPE(mode)) {
         case T_FIXNUM:
                 x.argc = 3;
-                x.mode = NUM2INT(mode);
+                x.mode = NUM2UINT(mode);
                 break;
         case T_NIL:
                 if (x.oflags & O_CREAT) {