summaryrefslogtreecommitdiff
path: root/ext/dl/cptr.c
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-07-28 03:32:45 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-07-28 03:32:45 +0000
commit79d8d7439a84782f4c7155fcc8f9da4471a38823 (patch)
treef9291aff5e183f64bba00d29c82a5c9bafad8cc1 /ext/dl/cptr.c
parente2b800113cae1e3b5b28e24f520fe694bd27506b (diff)
* ext/dl/cptr.c (rb_dlptr_s_to_ptr): fix wrapping condition.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@32718 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'ext/dl/cptr.c')
-rw-r--r--ext/dl/cptr.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/ext/dl/cptr.c b/ext/dl/cptr.c
index c2fb60540ec..02535f3949a 100644
--- a/ext/dl/cptr.c
+++ b/ext/dl/cptr.c
@@ -622,7 +622,7 @@ rb_dlptr_s_to_ptr(VALUE self, VALUE val)
}
else{
VALUE num = rb_Integer(val);
- if (num != val) wrap = 0;
+ if (num == val) wrap = 0;
ptr = rb_dlptr_new(NUM2PTR(num), 0, NULL);
}
OBJ_INFECT(ptr, val);