catch up r60088 for DOSISH.

* file.c (rb_file_s_rename): src and dst are used only on DOSISH env.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@60092 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
ko1 2017-10-02 01:22:11 +00:00
parent 6c29f232a7
commit d0566062f9

2
file.c
View File

@ -2915,6 +2915,8 @@ rb_file_s_rename(VALUE klass, VALUE from, VALUE to)
RUBY_UBF_IO, 0) < 0) {
int e = errno;
#if defined DOSISH
const char *src = StringValueCStr(f);
const char *dst = StringValueCStr(t);
switch (e) {
case EEXIST:
if (chmod(dst, 0666) == 0 &&