Project

General

Profile

Actions

Bug #11462

closed

win32 readlink doesn't support dedup

Added by scorpion007 (Alex Budovski) over 8 years ago. Updated over 8 years ago.

Status:
Closed
Assignee:
-
Target version:
-
ruby -v:
latest master
[ruby-core:<unknown>]

Description

During build:

./tool/mkconfig.rb:13:in require': Invalid argument @ rb_readlink - E:/dev/ruby/lib/fileutils.rb (Errno::EINVAL) from ./tool/mkconfig.rb:13:in '
NMAKE : fatal error U1077: '.\miniruby.exe' : return code '0x1'
Stop.

This is due to:

 # Child-SP          RetAddr           Call Site
00 000000a8`1191d540 00007ff7`14929486 miniruby!rb_w32_wreadlink+0x209 [e:\dev\ruby\win32\win32.c @ 4743]
01 000000a8`1191dde0 00007ff7`1476c941 miniruby!rb_readlink+0x196 [e:\dev\ruby\win32\file.c @ 681]
02 000000a8`1191e080 00007ff7`14767400 miniruby!realpath_rec+0x7a1 [e:\dev\ruby\file.c @ 3791]
03 000000a8`1191e230 00007ff7`1475da4a miniruby!rb_realpath_internal+0x5b0 [e:\dev\ruby\file.c @ 3895]
04 000000a8`1191e320 00007ff7`1475dbfb miniruby!rb_load_internal0+0x1ba [e:\dev\ruby\load.c @ 610]
05 000000a8`1191e4f0 00007ff7`1475bdff miniruby!rb_load_internal+0x2b [e:\dev\ruby\load.c @ 646]
06 000000a8`1191e530 00007ff7`1475b99b miniruby!rb_require_internal+0x22f [e:\dev\ruby\load.c @ 1016]
07 000000a8`1191e700 00007ff7`1475b96f miniruby!rb_require_safe+0x1b [e:\dev\ruby\load.c @ 1062]
08 000000a8`1191e740 00007ff7`148e2053 miniruby!rb_f_require+0x1f [e:\dev\ruby\load.c @ 830]
09 000000a8`1191e770 00007ff7`148e32eb miniruby!call_cfunc_1+0x33 [e:\dev\ruby\vm_insnhelper.c @ 1444]
0a 000000a8`1191e7a0 00007ff7`148e35d6 miniruby!vm_call_cfunc_with_frame+0x38b [e:\dev\ruby\vm_insnhelper.c @ 1604]
0b 000000a8`1191e8b0 00007ff7`148e3a1e miniruby!vm_call_cfunc+0x66 [e:\dev\ruby\vm_insnhelper.c @ 1700]
0c 000000a8`1191e8e0 00007ff7`148de787 miniruby!vm_call_method+0x12e [e:\dev\ruby\vm_insnhelper.c @ 1984]
0d 000000a8`1191ea00 00007ff7`148e92db miniruby!vm_call_general+0x27 [e:\dev\ruby\vm_insnhelper.c @ 2146]
0e 000000a8`1191ea30 00007ff7`148f18ec miniruby!vm_exec_core+0x304b [e:\dev\ruby\insns.def @ 976]
0f 000000a8`1191f740 00007ff7`148da6cc miniruby!vm_exec+0xdc [e:\dev\ruby\vm.c @ 1472]
10 000000a8`1191f9a0 00007ff7`14758cd9 miniruby!rb_iseq_eval_main+0x2c [e:\dev\ruby\vm.c @ 1714]
11 000000a8`1191f9e0 00007ff7`147574dd miniruby!ruby_exec_internal+0xe9 [e:\dev\ruby\eval.c @ 250]
12 000000a8`1191fb80 00007ff7`14756e83 miniruby!ruby_exec_node+0x1d [e:\dev\ruby\eval.c @ 313]
13 000000a8`1191fbb0 00007ff7`14701041 miniruby!ruby_run_node+0x33 [e:\dev\ruby\eval.c @ 304]
14 000000a8`1191fbf0 00007ff7`1492a1dd miniruby!main+0x41 [e:\dev\ruby\main.c @ 38]
15 000000a8`1191fc30 00007ff7`1492a30e miniruby!__tmainCRTStartup+0x19d [f:\dd\vctools\crt\crtw32\dllstuff\crtexe.c @ 626]
16 000000a8`1191fca0 00007ffd`1e3413d2 miniruby!mainCRTStartup+0xe [f:\dd\vctools\crt\crtw32\dllstuff\crtexe.c @ 466]
17 000000a8`1191fcd0 00007ffd`20295454 KERNEL32!BaseThreadInitThunk+0x22 [d:\9147\base\win32\client\thread.c @ 78]
18 000000a8`1191fd00 00000000`00000000 ntdll!RtlUserThreadStart+0x34 [d:\blue\minkernel\ntdll\rtlstrt.c @ 1026]
0:000> dt rp
Local var @ 0xa81191d5b0 
   +0x000 ReparseTag       : 0x80000013
   +0x004 ReparseDataLength : 0x7c
   +0x006 Reserved         : 0
   +0x008 SymbolicLinkReparseBuffer : <unnamed-tag>
   +0x008 MountPointReparseBuffer : <unnamed-tag>

0x80000013 is IO_REPARSE_TAG_DEDUP. I am using Windows Server Data Dedup on this volume. (http://blogs.technet.com/b/filecab/archive/2012/05/21/introduction-to-data-deduplication-in-windows-server-2012.aspx)

So we return EINVAL

    else if (rp.ReparseTag != IO_REPARSE_TAG_SYMLINK &&
	     rp.ReparseTag != IO_REPARSE_TAG_MOUNT_POINT){
	e = EINVAL;
    }

Related issues 1 (0 open1 closed)

Related to Ruby master - Bug #11478: symlinks support broken on win32ClosedActions
Actions #1

Updated by scorpion007 (Alex Budovski) over 8 years ago

Command line

'.\miniruby.exe -I./lib -I.  ./tool/mkconfig.rb -timestamp=./.rbconfig.time  -arch=x64-mswin64_120 -version="2.3.0"  -install_name=ruby  -so_name=x64-msvcr120-ruby230_d rbconfig.rb'
Actions #2

Updated by nobu (Nobuyoshi Nakada) over 8 years ago

  • Status changed from Open to Closed

Applied in changeset r51640.


win32.c: support known reparse points only

  • win32/win32.c (winnt_lstat): check reparse point tags and treat
    supported tags only as symbolic links.
    [ruby-core:70454] [Bug #11462]
Actions #3

Updated by nobu (Nobuyoshi Nakada) over 8 years ago

  • Related to Bug #11478: symlinks support broken on win32 added
Actions

Also available in: Atom PDF

Like0
Like0Like0Like0