We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e1f5d8f commit edcaa40Copy full SHA for edcaa40
ext/bson/util.c
@@ -170,6 +170,9 @@ VALUE pvt_load_secure_random(VALUE _arg) {
170
pvt_SecureRandom = rb_const_get(rb_cObject, rb_intern("SecureRandom"));
171
pvt_has_random_number = rb_respond_to(pvt_SecureRandom, rb_intern("random_number"));
172
173
+ // mark SecureRandom so it does not get moved
174
+ rb_global_variable(&pvt_SecureRandom);
175
+
176
return Qnil;
177
}
178
0 commit comments