Module: wine Branch: master Commit: 5b07326368816581c4adf478569f398366fc270a URL: http://source.winehq.org/git/wine.git/?a=commit;h=5b07326368816581c4adf47856...
Author: YongHao Hu christopherwuy@gmail.com Date: Mon Aug 10 14:46:32 2015 +0800
msvcp110: Add tr2_sys__Remove_dir_wchar implementation and test.
---
dlls/msvcp110/msvcp110.spec | 4 ++-- dlls/msvcp120/msvcp120.spec | 4 ++-- dlls/msvcp120/tests/msvcp120.c | 11 ++++++++--- dlls/msvcp120_app/msvcp120_app.spec | 4 ++-- dlls/msvcp90/ios.c | 8 ++++++++ 5 files changed, 22 insertions(+), 9 deletions(-)
diff --git a/dlls/msvcp110/msvcp110.spec b/dlls/msvcp110/msvcp110.spec index c1c6212..fb22ca1 100644 --- a/dlls/msvcp110/msvcp110.spec +++ b/dlls/msvcp110/msvcp110.spec @@ -1720,8 +1720,8 @@ @ stub -arch=win64 ?_Release@_Pad@std@@QEAAXXZ @ cdecl -arch=win32 ?_Remove_dir@sys@tr2@std@@YA_NPBD@Z(str) tr2_sys__Remove_dir @ cdecl -arch=win64 ?_Remove_dir@sys@tr2@std@@YA_NPEBD@Z(str) tr2_sys__Remove_dir -@ stub -arch=win32 ?_Remove_dir@sys@tr2@std@@YA_NPB_W@Z -@ stub -arch=win64 ?_Remove_dir@sys@tr2@std@@YA_NPEB_W@Z +@ cdecl -arch=win32 ?_Remove_dir@sys@tr2@std@@YA_NPB_W@Z(wstr) tr2_sys__Remove_dir_wchar +@ cdecl -arch=win64 ?_Remove_dir@sys@tr2@std@@YA_NPEB_W@Z(wstr) tr2_sys__Remove_dir_wchar @ cdecl -arch=win32 ?_Rename@sys@tr2@std@@YAHPBD0@Z(str str) tr2_sys__Rename @ cdecl -arch=win64 ?_Rename@sys@tr2@std@@YAHPEBD0@Z(str str) tr2_sys__Rename @ stub -arch=win32 ?_Rename@sys@tr2@std@@YAHPB_W0@Z diff --git a/dlls/msvcp120/msvcp120.spec b/dlls/msvcp120/msvcp120.spec index e990eaf..8a7b6d7 100644 --- a/dlls/msvcp120/msvcp120.spec +++ b/dlls/msvcp120/msvcp120.spec @@ -1681,8 +1681,8 @@ @ stub -arch=win64 ?_Release@_Pad@std@@QEAAXXZ @ cdecl -arch=win32 ?_Remove_dir@sys@tr2@std@@YA_NPBD@Z(str) tr2_sys__Remove_dir @ cdecl -arch=win64 ?_Remove_dir@sys@tr2@std@@YA_NPEBD@Z(str) tr2_sys__Remove_dir -@ stub -arch=win32 ?_Remove_dir@sys@tr2@std@@YA_NPB_W@Z -@ stub -arch=win64 ?_Remove_dir@sys@tr2@std@@YA_NPEB_W@Z +@ cdecl -arch=win32 ?_Remove_dir@sys@tr2@std@@YA_NPB_W@Z(wstr) tr2_sys__Remove_dir_wchar +@ cdecl -arch=win64 ?_Remove_dir@sys@tr2@std@@YA_NPEB_W@Z(wstr) tr2_sys__Remove_dir_wchar @ cdecl -arch=win32 ?_Rename@sys@tr2@std@@YAHPBD0@Z(str str) tr2_sys__Rename @ cdecl -arch=win64 ?_Rename@sys@tr2@std@@YAHPEBD0@Z(str str) tr2_sys__Rename @ stub -arch=win32 ?_Rename@sys@tr2@std@@YAHPB_W0@Z diff --git a/dlls/msvcp120/tests/msvcp120.c b/dlls/msvcp120/tests/msvcp120.c index 85e9354..6bbe11e 100644 --- a/dlls/msvcp120/tests/msvcp120.c +++ b/dlls/msvcp120/tests/msvcp120.c @@ -83,6 +83,7 @@ static MSVCP_bool (__cdecl *p_tr2_sys__Current_set_wchar)(WCHAR const*); static int (__cdecl *p_tr2_sys__Make_dir)(char const*); static int (__cdecl *p_tr2_sys__Make_dir_wchar)(WCHAR const*); static MSVCP_bool (__cdecl *p_tr2_sys__Remove_dir)(char const*); +static MSVCP_bool (__cdecl *p_tr2_sys__Remove_dir_wchar)(WCHAR const*); static int (__cdecl *p_tr2_sys__Copy_file)(char const*, char const*, MSVCP_bool); static int (__cdecl *p_tr2_sys__Rename)(char const*, char const*); static struct space_info (__cdecl *p_tr2_sys__Statvfs)(char const*); @@ -138,6 +139,8 @@ static BOOL init(void) "?_Make_dir@sys@tr2@std@@YAHPEB_W@Z"); SET(p_tr2_sys__Remove_dir, "?_Remove_dir@sys@tr2@std@@YA_NPEBD@Z"); + SET(p_tr2_sys__Remove_dir_wchar, + "?_Remove_dir@sys@tr2@std@@YA_NPEB_W@Z"); SET(p_tr2_sys__Copy_file, "?_Copy_file@sys@tr2@std@@YAHPEBD0_N@Z"); SET(p_tr2_sys__Rename, @@ -171,6 +174,8 @@ static BOOL init(void) "?_Make_dir@sys@tr2@std@@YAHPB_W@Z"); SET(p_tr2_sys__Remove_dir, "?_Remove_dir@sys@tr2@std@@YA_NPBD@Z"); + SET(p_tr2_sys__Remove_dir_wchar, + "?_Remove_dir@sys@tr2@std@@YA_NPB_W@Z"); SET(p_tr2_sys__Copy_file, "?_Copy_file@sys@tr2@std@@YAHPBD0_N@Z"); SET(p_tr2_sys__Rename, @@ -427,7 +432,7 @@ static void test_tr2_sys__File_size(void)
ok(DeleteFileA("tr2_test_dir/f1"), "expect tr2_test_dir/f1 to exist\n"); ok(DeleteFileA("tr2_test_dir/f2"), "expect tr2_test_dir/f2 to exist\n"); - ok(RemoveDirectoryA("tr2_test_dir"), "expect tr2_test_dir to exist\n"); + ok(p_tr2_sys__Remove_dir("tr2_test_dir"), "expect tr2_test_dir to exist\n"); }
static void test_tr2_sys__Equivalent(void) @@ -586,8 +591,8 @@ static void test_tr2_sys__Make_dir(void) ret = p_tr2_sys__Make_dir_wchar(testW); ok(ret == 1, "tr2_sys__Make_dir(): expect: 1, got %d\n", ret);
- ok(RemoveDirectoryA("tr2_test_dir"), "expect tr2_test_dir to exist\n"); - ok(RemoveDirectoryW(testW), "expect wd to exist\n"); + ok(p_tr2_sys__Remove_dir("tr2_test_dir"), "expect tr2_test_dir to exist\n"); + ok(p_tr2_sys__Remove_dir_wchar(testW), "expect wd to exist\n"); }
static void test_tr2_sys__Remove_dir(void) diff --git a/dlls/msvcp120_app/msvcp120_app.spec b/dlls/msvcp120_app/msvcp120_app.spec index b20d507..d05b3d4 100644 --- a/dlls/msvcp120_app/msvcp120_app.spec +++ b/dlls/msvcp120_app/msvcp120_app.spec @@ -1681,8 +1681,8 @@ @ stub -arch=win64 ?_Release@_Pad@std@@QEAAXXZ @ cdecl -arch=win32 ?_Remove_dir@sys@tr2@std@@YA_NPBD@Z(str) msvcp120.?_Remove_dir@sys@tr2@std@@YA_NPBD@Z @ cdecl -arch=win64 ?_Remove_dir@sys@tr2@std@@YA_NPEBD@Z(str) msvcp120.?_Remove_dir@sys@tr2@std@@YA_NPEBD@Z -@ stub -arch=win32 ?_Remove_dir@sys@tr2@std@@YA_NPB_W@Z -@ stub -arch=win64 ?_Remove_dir@sys@tr2@std@@YA_NPEB_W@Z +@ cdecl -arch=win32 ?_Remove_dir@sys@tr2@std@@YA_NPB_W@Z(wstr) msvcp120.?_Remove_dir@sys@tr2@std@@YA_NPB_W@Z +@ cdecl -arch=win64 ?_Remove_dir@sys@tr2@std@@YA_NPEB_W@Z(wstr) msvcp120.?_Remove_dir@sys@tr2@std@@YA_NPEB_W@Z @ cdecl -arch=win32 ?_Rename@sys@tr2@std@@YAHPBD0@Z(str str) msvcp120.?_Rename@sys@tr2@std@@YAHPBD0@Z @ cdecl -arch=win64 ?_Rename@sys@tr2@std@@YAHPEBD0@Z(str str) msvcp120.?_Rename@sys@tr2@std@@YAHPEBD0@Z @ stub -arch=win32 ?_Rename@sys@tr2@std@@YAHPB_W0@Z diff --git a/dlls/msvcp90/ios.c b/dlls/msvcp90/ios.c index c01d187..88d6453 100644 --- a/dlls/msvcp90/ios.c +++ b/dlls/msvcp90/ios.c @@ -14825,6 +14825,14 @@ int __cdecl tr2_sys__Make_dir_wchar(WCHAR const* path) return 1; }
+/* ?_Remove_dir@sys@tr2@std@@YA_NPB_W@Z */ +/* ?_Remove_dir@sys@tr2@std@@YA_NPEB_W@Z */ +MSVCP_bool __cdecl tr2_sys__Remove_dir_wchar(WCHAR const* path) +{ + TRACE("(%s)\n", debugstr_w(path)); + return RemoveDirectoryW(path) != 0; +} + /* ??1_Winit@std@@QAE@XZ */ /* ??1_Winit@std@@QAE@XZ */ DEFINE_THISCALL_WRAPPER(_Winit_dtor, 4)