1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

string.c: fix up r60748

An #ifdef was missing in r60748 and build broke on systems without
crypt_r().

https://rubyci.org/logs/rubyci.s3.amazonaws.com/unstable11s/ruby-trunk/log/20171112T162503Z.fail.html.gz

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60749 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
rhe 2017-11-12 17:10:29 +00:00
parent 0b845a8458
commit a82aaea719

View file

@ -8889,7 +8889,9 @@ rb_str_crypt(VALUE str, VALUE salt)
rb_sys_fail("crypt");
}
result = rb_str_new_cstr(res);
#ifdef HAVE_CRYPT_R
ALLOCV_END(databuf);
#endif
FL_SET_RAW(result, OBJ_TAINTED_RAW(str) | OBJ_TAINTED_RAW(salt));
return result;
}