Issue #12171 has been updated by Yui NARUSE.

Backport changed from 2.1: DONTNEED, 2.2: DONTNEED, 2.3: REQUIRED to 2.1: DONTNEED, 2.2: DONTNEED, 2.3: DONE

ruby_2_3 r54412 merged revision(s) 54094.

----------------------------------------
Bug #12171: TestFile#test_file_share_delete failure
https://bugs.ruby-lang.org/issues/12171#change-57836

* Author: Tsuyoshi Morita
* Status: Closed
* Priority: Normal
* Assignee: 
* ruby -v: ruby 2.3.0p0 (2015-12-25 revision 53290) [i386-mingw32]
* Backport: 2.1: DONTNEED, 2.2: DONTNEED, 2.3: DONE
----------------------------------------
I got an failure in Mingw-w64 32bit.

~~~
1) Failure:
TestFile#test_file_share_delete [E:/Jenkins/jobs/RubyInstaller32_ruby23_4.7.2/workspace/sandbox/ruby_2_3/test/ruby/test_file.rb:418]:
Exception raised:
<#<Errno::EACCES: Permission denied @ unlink_internal - c:/temp/test_file_share_delete20160211-11728-1qcjzrd/x>>.

~~~

The cause is from O_SHARE_DELETE definition.

~~~
  include/ruby/win32.h:130:#define O_SHARE_DELETE 0x80000000 /* for rb_w32_open(), rb_w32_wopen() */
  file.c:6044:    rb_define_const(rb_mFConst, "SHARE_DELETE", INT2FIX(O_SHARE_DELETE));
~~~

In 32bit machine, 0x80000000 is out of Fixnum range.



-- 
https://bugs.ruby-lang.org/

Unsubscribe: <mailto:ruby-core-request / ruby-lang.org?subject=unsubscribe>
<http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>