msvcp: Implement the WCHAR version of _Symlink.

Signed-off-by: Stefan Dösinger <stefan@codeweavers.com>
Signed-off-by: Piotr Caban <piotr@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Stefan Dösinger 2017-10-10 17:09:44 +02:00 committed by Alexandre Julliard
parent eea0f37a1a
commit 12dadd04cb
4 changed files with 19 additions and 5 deletions

View File

@ -1734,8 +1734,8 @@
@ cdecl -arch=win64 ?_Swap_all@_Container_base12@std@@QEAAXAEAU12@@Z(ptr ptr) _Container_base12__Swap_all
@ cdecl -arch=win32 ?_Symlink@sys@tr2@std@@YAHPBD0@Z(str str) tr2_sys__Symlink
@ cdecl -arch=win64 ?_Symlink@sys@tr2@std@@YAHPEBD0@Z(str str) tr2_sys__Symlink
@ stub -arch=win32 ?_Symlink@sys@tr2@std@@YAHPB_W0@Z
@ stub -arch=win64 ?_Symlink@sys@tr2@std@@YAHPEB_W0@Z
@ cdecl -arch=win32 ?_Symlink@sys@tr2@std@@YAHPB_W0@Z(wstr wstr) tr2_sys__Symlink_wchar
@ cdecl -arch=win64 ?_Symlink@sys@tr2@std@@YAHPEB_W0@Z(wstr wstr) tr2_sys__Symlink_wchar
@ extern ?_Sync@ios_base@std@@0_NA ios_base_Sync
@ stub -arch=win32 ?_Syserror_map@std@@YAPBDH@Z
@ stub -arch=win64 ?_Syserror_map@std@@YAPEBDH@Z

View File

@ -1734,8 +1734,8 @@
@ cdecl -arch=win64 ?_Swap_all@_Container_base12@std@@QEAAXAEAU12@@Z(ptr ptr) msvcp120.?_Swap_all@_Container_base12@std@@QEAAXAEAU12@@Z
@ cdecl -arch=win32 ?_Symlink@sys@tr2@std@@YAHPBD0@Z(str str) msvcp120.?_Symlink@sys@tr2@std@@YAHPBD0@Z
@ cdecl -arch=win64 ?_Symlink@sys@tr2@std@@YAHPEBD0@Z(str str) msvcp120.?_Symlink@sys@tr2@std@@YAHPEBD0@Z
@ stub -arch=win32 ?_Symlink@sys@tr2@std@@YAHPB_W0@Z
@ stub -arch=win64 ?_Symlink@sys@tr2@std@@YAHPEB_W0@Z
@ cdecl -arch=win32 ?_Symlink@sys@tr2@std@@YAHPB_W0@Z(wstr wstr) msvcp120.?_Symlink@sys@tr2@std@@YAHPB_W0@Z
@ cdecl -arch=win64 ?_Symlink@sys@tr2@std@@YAHPEB_W0@Z(wstr wstr) msvcp120.?_Symlink@sys@tr2@std@@YAHPEB_W0@Z
@ extern ?_Sync@ios_base@std@@0_NA msvcp120.?_Sync@ios_base@std@@0_NA
@ stub -arch=win32 ?_Syserror_map@std@@YAPBDH@Z
@ stub -arch=win64 ?_Syserror_map@std@@YAPEBDH@Z

View File

@ -3716,7 +3716,7 @@
@ cdecl _Stoulx(ptr ptr long ptr) _Stoulx
@ cdecl _Strcoll(ptr ptr ptr ptr ptr) _Strcoll
@ stub _Strxfrm
@ stub _Symlink
@ cdecl _Symlink(wstr wstr) tr2_sys__Symlink_wchar
@ stub _Symlink_get
@ stub _Temp_get
@ stub _Thrd_abort

View File

@ -15049,6 +15049,20 @@ int __cdecl tr2_sys__Symlink(char const* existing_file_name, char const* file_na
return GetLastError();
}
/* ?_Symlink@sys@tr2@std@@YAHPB_W0@Z */
/* ?_Symlink@sys@tr2@std@@YAHPEB_W0@Z */
/* _Symlink */
int __cdecl tr2_sys__Symlink_wchar(WCHAR const* existing_file_name, WCHAR const* file_name)
{
TRACE("(%s %s)\n", debugstr_w(existing_file_name), debugstr_w(file_name));
if(!existing_file_name || !file_name)
return ERROR_INVALID_PARAMETER;
if(CreateSymbolicLinkW(file_name, existing_file_name, 0))
return ERROR_SUCCESS;
return GetLastError();
}
/* ?_Unlink@sys@tr2@std@@YAHPBD@Z */
/* ?_Unlink@sys@tr2@std@@YAHPEBD@Z */
int __cdecl tr2_sys__Unlink(char const* path)