-
Notifications
You must be signed in to change notification settings - Fork 194
Closed
Description
Ref: ruby/openssl#831
RuntimeError: temporal locking immutable string
string.c:102:in `rb_str_locktmp'
string.c:102:in `rb_str_locktmp'
/home/runner/.rubies/truffleruby-24.1.1/lib/truffle/truffle/cext_ruby.rb:38:in `syswrite_nonblock'
Whereas MRI doesn't care whether the string is frozen or not, it will lock it either way:
VALUE
rb_str_locktmp(VALUE str)
{
if (FL_TEST(str, STR_TMPLOCK)) {
rb_raise(rb_eRuntimeError, "temporal locking already locked string");
}
FL_SET(str, STR_TMPLOCK);
return str;
}
VALUE
rb_str_unlocktmp(VALUE str)
{
if (!FL_TEST(str, STR_TMPLOCK)) {
rb_raise(rb_eRuntimeError, "temporal unlocking already unlocked string");
}
FL_UNSET(str, STR_TMPLOCK);
return str;
}