winehq.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2025
February
January
2024
December
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
October
September
August
July
June
May
April
March
February
January
2007
December
November
October
September
August
July
June
May
April
March
February
January
2006
December
November
October
September
August
July
June
May
April
March
February
January
2005
December
November
October
September
August
July
June
May
April
March
February
January
2004
December
November
October
September
August
July
June
May
April
March
February
January
2003
December
November
October
September
August
July
June
May
April
March
February
January
2002
December
November
October
September
August
July
June
May
April
March
February
January
2001
December
November
October
September
August
July
June
May
April
March
February
List overview
wine-commits
October 2018
----- 2025 -----
February 2025
January 2025
----- 2024 -----
December 2024
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
October 2008
September 2008
August 2008
July 2008
June 2008
May 2008
April 2008
March 2008
February 2008
January 2008
----- 2007 -----
December 2007
November 2007
October 2007
September 2007
August 2007
July 2007
June 2007
May 2007
April 2007
March 2007
February 2007
January 2007
----- 2006 -----
December 2006
November 2006
October 2006
September 2006
August 2006
July 2006
June 2006
May 2006
April 2006
March 2006
February 2006
January 2006
----- 2005 -----
December 2005
November 2005
October 2005
September 2005
August 2005
July 2005
June 2005
May 2005
April 2005
March 2005
February 2005
January 2005
----- 2004 -----
December 2004
November 2004
October 2004
September 2004
August 2004
July 2004
June 2004
May 2004
April 2004
March 2004
February 2004
January 2004
----- 2003 -----
December 2003
November 2003
October 2003
September 2003
August 2003
July 2003
June 2003
May 2003
April 2003
March 2003
February 2003
January 2003
----- 2002 -----
December 2002
November 2002
October 2002
September 2002
August 2002
July 2002
June 2002
May 2002
April 2002
March 2002
February 2002
January 2002
----- 2001 -----
December 2001
November 2001
October 2001
September 2001
August 2001
July 2001
June 2001
May 2001
April 2001
March 2001
February 2001
wine-commits@winehq.org
1 participants
602 discussions
Start a n
N
ew thread
Alexandre Julliard : kernel32: Pass the standard process parameters structure to fork_and_exec().
by Alexandre Julliard
15 Oct '18
15 Oct '18
Module: wine Branch: master Commit: 27ba57e80444e2ba25e7f9a59d067bd022b678da URL:
https://source.winehq.org/git/wine.git/?a=commit;h=27ba57e80444e2ba25e7f9a5…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Mon Oct 15 17:05:31 2018 +0200 kernel32: Pass the standard process parameters structure to fork_and_exec(). Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/kernel32/process.c | 58 +++++++++++-------------------------------------- 1 file changed, 13 insertions(+), 45 deletions(-) diff --git a/dlls/kernel32/process.c b/dlls/kernel32/process.c index 6c9c8cf..f56bb09 100644 --- a/dlls/kernel32/process.c +++ b/dlls/kernel32/process.c @@ -1663,14 +1663,13 @@ static char **build_envp( const WCHAR *envW ) * * Fork and exec a new Unix binary, checking for errors. */ -static int fork_and_exec( const char *filename, const WCHAR *cmdline, const WCHAR *env, - const char *newdir, DWORD flags, STARTUPINFOW *startup ) +static int fork_and_exec( const RTL_USER_PROCESS_PARAMETERS *params, const char *newdir, DWORD flags ) { int fd[2], stdin_fd = -1, stdout_fd = -1, stderr_fd = -1; int pid, err; - char **argv, **envp; + char *filename, **argv, **envp; - if (!env) env = GetEnvironmentStringsW(); + if (!(filename = wine_get_unix_file_name( params->ImagePathName.Buffer ))) return -1; #ifdef HAVE_PIPE2 if (pipe2( fd, O_CLOEXEC ) == -1) @@ -1679,42 +1678,19 @@ static int fork_and_exec( const char *filename, const WCHAR *cmdline, const WCHA if (pipe(fd) == -1) { SetLastError( ERROR_TOO_MANY_OPEN_FILES ); + HeapFree( GetProcessHeap(), 0, filename ); return -1; } fcntl( fd[0], F_SETFD, FD_CLOEXEC ); fcntl( fd[1], F_SETFD, FD_CLOEXEC ); } - if (!(flags & (CREATE_NEW_PROCESS_GROUP | CREATE_NEW_CONSOLE | DETACHED_PROCESS))) - { - HANDLE hstdin, hstdout, hstderr; - - if (startup->dwFlags & STARTF_USESTDHANDLES) - { - hstdin = startup->hStdInput; - hstdout = startup->hStdOutput; - hstderr = startup->hStdError; - } - else - { - hstdin = GetStdHandle(STD_INPUT_HANDLE); - hstdout = GetStdHandle(STD_OUTPUT_HANDLE); - hstderr = GetStdHandle(STD_ERROR_HANDLE); - } + wine_server_handle_to_fd( params->hStdInput, FILE_READ_DATA, &stdin_fd, NULL ); + wine_server_handle_to_fd( params->hStdOutput, FILE_WRITE_DATA, &stdout_fd, NULL ); + wine_server_handle_to_fd( params->hStdError, FILE_WRITE_DATA, &stderr_fd, NULL ); - if (is_console_handle( hstdin )) - hstdin = wine_server_ptr_handle( console_handle_unmap( hstdin )); - if (is_console_handle( hstdout )) - hstdout = wine_server_ptr_handle( console_handle_unmap( hstdout )); - if (is_console_handle( hstderr )) - hstderr = wine_server_ptr_handle( console_handle_unmap( hstderr )); - wine_server_handle_to_fd( hstdin, FILE_READ_DATA, &stdin_fd, NULL ); - wine_server_handle_to_fd( hstdout, FILE_WRITE_DATA, &stdout_fd, NULL ); - wine_server_handle_to_fd( hstderr, FILE_WRITE_DATA, &stderr_fd, NULL ); - } - - argv = build_argv( cmdline, 0 ); - envp = build_envp( env ); + argv = build_argv( params->CommandLine.Buffer, 0 ); + envp = build_envp( params->Environment ); if (!(pid = fork())) /* child */ { @@ -1772,6 +1748,7 @@ static int fork_and_exec( const char *filename, const WCHAR *cmdline, const WCHA } HeapFree( GetProcessHeap(), 0, argv ); HeapFree( GetProcessHeap(), 0, envp ); + HeapFree( GetProcessHeap(), 0, filename ); if (stdin_fd != -1) close( stdin_fd ); if (stdout_fd != -1) close( stdout_fd ); if (stderr_fd != -1) close( stderr_fd ); @@ -2743,18 +2720,9 @@ static BOOL create_process_impl( LPCWSTR app_name, LPWSTR cmd_line, LPSECURITY_A } /* fall through */ case BINARY_UNIX_EXE: - { - /* unknown file, try as unix executable */ - char *unix_name; - - TRACE( "starting %s as Unix binary\n", debugstr_w(name) ); - - if ((unix_name = wine_get_unix_file_name( name ))) - { - retv = (fork_and_exec( unix_name, tidy_cmdline, envW, unixdir, flags, startup_info ) != -1); - HeapFree( GetProcessHeap(), 0, unix_name ); - } - } + /* unknown file, try as unix executable */ + TRACE( "starting %s as Unix binary\n", debugstr_w(name) ); + retv = (fork_and_exec( params, unixdir, flags ) != -1); break; } if (hFile) CloseHandle( hFile );
1
0
0
0
Alexandre Julliard : kernel32: Pass the standard process parameters structure to create_process().
by Alexandre Julliard
15 Oct '18
15 Oct '18
Module: wine Branch: master Commit: ed551282b4121f94f619682ad0d2fcbf982d7f37 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=ed551282b4121f94f619682a…
Author: Alexandre Julliard <julliard(a)winehq.org> Date: Mon Oct 15 17:00:31 2018 +0200 kernel32: Pass the standard process parameters structure to create_process(). Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/kernel32/process.c | 135 ++++++++++++++++++++++++++++-------------------- 1 file changed, 80 insertions(+), 55 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=ed551282b4121f94f619…
1
0
0
0
Louis Lenders : kernel32: Add stub for MoveFileTransacted{A,W}.
by Alexandre Julliard
15 Oct '18
15 Oct '18
Module: wine Branch: master Commit: 35f62f644d069a2bb568a17f35a1af9a089b585a URL:
https://source.winehq.org/git/wine.git/?a=commit;h=35f62f644d069a2bb568a17f…
Author: Louis Lenders <xerox.xerox2000x(a)gmail.com> Date: Mon Oct 15 14:28:32 2018 +0200 kernel32: Add stub for MoveFileTransacted{A,W}. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=45995
Signed-off-by: Louis Lenders <xerox.xerox2000x(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/kernel32/kernel32.spec | 4 ++-- dlls/kernel32/path.c | 19 +++++++++++++++++++ include/winbase.h | 3 +++ 3 files changed, 24 insertions(+), 2 deletions(-) diff --git a/dlls/kernel32/kernel32.spec b/dlls/kernel32/kernel32.spec index e17ee97..52120dd 100644 --- a/dlls/kernel32/kernel32.spec +++ b/dlls/kernel32/kernel32.spec @@ -1088,8 +1088,8 @@ @ stdcall MoveFileA(str str) @ stdcall MoveFileExA(str str long) @ stdcall MoveFileExW(wstr wstr long) -# @ stub MoveFileTransactedA -# @ stub MoveFileTransactedW +@ stdcall MoveFileTransactedA(str str ptr ptr long ptr) +@ stdcall MoveFileTransactedW(wstr wstr ptr ptr long ptr) @ stdcall MoveFileW(wstr wstr) @ stdcall MoveFileWithProgressA(str str ptr ptr long) @ stdcall MoveFileWithProgressW(wstr wstr ptr ptr long) diff --git a/dlls/kernel32/path.c b/dlls/kernel32/path.c index 841a12b..7dcb937 100644 --- a/dlls/kernel32/path.c +++ b/dlls/kernel32/path.c @@ -1268,6 +1268,25 @@ BOOL WINAPI CopyFileExA(LPCSTR sourceFilename, LPCSTR destFilename, return ret; } +/************************************************************************** + * MoveFileTransactedA (KERNEL32.@) + */ +BOOL WINAPI MoveFileTransactedA(const char *source, const char *dest, LPPROGRESS_ROUTINE progress, void *data, DWORD flags, HANDLE handle) +{ + FIXME("(%s, %s, %p, %p, %d, %p)\n", debugstr_a(source), debugstr_a(dest), progress, data, flags, handle); + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +} + +/************************************************************************** + * MoveFileTransactedW (KERNEL32.@) + */ +BOOL WINAPI MoveFileTransactedW(const WCHAR *source, const WCHAR *dest, LPPROGRESS_ROUTINE progress, void *data, DWORD flags, HANDLE handle) +{ + FIXME("(%s, %s, %p, %p, %d, %p)\n", debugstr_w(source), debugstr_w(dest), progress, data, flags, handle); + SetLastError(ERROR_CALL_NOT_IMPLEMENTED); + return FALSE; +} /************************************************************************** * MoveFileWithProgressW (KERNEL32.@) diff --git a/include/winbase.h b/include/winbase.h index ea450e1..7b99424 100644 --- a/include/winbase.h +++ b/include/winbase.h @@ -2425,6 +2425,9 @@ WINBASEAPI BOOL WINAPI MoveFileW(LPCWSTR,LPCWSTR); WINBASEAPI BOOL WINAPI MoveFileExA(LPCSTR,LPCSTR,DWORD); WINBASEAPI BOOL WINAPI MoveFileExW(LPCWSTR,LPCWSTR,DWORD); #define MoveFileEx WINELIB_NAME_AW(MoveFileEx) +WINBASEAPI BOOL WINAPI MoveFileTransactedA(const char*,const char*,LPPROGRESS_ROUTINE,void*,DWORD,HANDLE); +WINBASEAPI BOOL WINAPI MoveFileTransactedW(const WCHAR*,const WCHAR*,LPPROGRESS_ROUTINE,void*,DWORD,HANDLE); +#define MoveFileTransacted WINELIB_NAME_AW(MoveFiletransacted) WINBASEAPI BOOL WINAPI MoveFileWithProgressA(LPCSTR,LPCSTR,LPPROGRESS_ROUTINE,LPVOID,DWORD); WINBASEAPI BOOL WINAPI MoveFileWithProgressW(LPCWSTR,LPCWSTR,LPPROGRESS_ROUTINE,LPVOID,DWORD); #define MoveFileWithProgress WINELIB_NAME_AW(MoveFileWithProgress)
1
0
0
0
Louis Lenders : mscms: Add stub for WcsEnumColorProfilesSize.
by Alexandre Julliard
15 Oct '18
15 Oct '18
Module: wine Branch: master Commit: 920b1371ac470f616280b37f1cd213081d3559a7 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=920b1371ac470f616280b37f…
Author: Louis Lenders <xerox.xerox2000x(a)gmail.com> Date: Mon Oct 15 14:21:31 2018 +0200 mscms: Add stub for WcsEnumColorProfilesSize. Wine-Bug:
https://bugs.winehq.org/show_bug.cgi?id=45994
Signed-off-by: Louis Lenders <xerox.xerox2000x(a)gmail.com> Signed-off-by: Hans Leidekker <hans(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/mscms/mscms.spec | 2 +- dlls/mscms/profile.c | 10 ++++++++++ include/icm.h | 7 +++++++ 3 files changed, 18 insertions(+), 1 deletion(-) diff --git a/dlls/mscms/mscms.spec b/dlls/mscms/mscms.spec index 9992bf5..f521ac6 100644 --- a/dlls/mscms/mscms.spec +++ b/dlls/mscms/mscms.spec @@ -89,7 +89,7 @@ @ stub WcsCreateIccProfile @ stub WcsDisassociateColorProfileFromDevice @ stub WcsEnumColorProfiles -@ stub WcsEnumColorProfilesSize +@ stdcall WcsEnumColorProfilesSize(long ptr ptr) @ stub WcsGetCalibrationManagementState @ stub WcsGetDefaultColorProfile @ stub WcsGetDefaultColorProfileSize diff --git a/dlls/mscms/profile.c b/dlls/mscms/profile.c index 53016ef..039a271 100644 --- a/dlls/mscms/profile.c +++ b/dlls/mscms/profile.c @@ -1535,3 +1535,13 @@ BOOL WINAPI WcsGetUsePerUserProfiles( const WCHAR* name, DWORD class, BOOL* use_ SetLastError( ERROR_CALL_NOT_IMPLEMENTED ); return FALSE; } + +/****************************************************************************** + * WcsEnumColorProfilesSize [MSCMS.@] + */ +BOOL WINAPI WcsEnumColorProfilesSize( WCS_PROFILE_MANAGEMENT_SCOPE scope, ENUMTYPEW *record, DWORD *size ) +{ + FIXME( "%d %p %p\n", scope, record, size ); + SetLastError( ERROR_CALL_NOT_IMPLEMENTED ); + return FALSE; +} diff --git a/include/icm.h b/include/icm.h index 8a666fa..fbbdede 100644 --- a/include/icm.h +++ b/include/icm.h @@ -176,6 +176,12 @@ typedef enum BM_16b_GRAY, } BMFORMAT, *PBMFORMAT, *LPBMFORMAT; +typedef enum +{ + WCS_PROFILE_MANAGEMENT_SCOPE_SYSTEM_WIDE, + WCS_PROFILE_MANAGEMENT_SCOPE_CURRENT_USER +} WCS_PROFILE_MANAGEMENT_SCOPE; + typedef BOOL (CALLBACK *PBMCALLBACKFN)(ULONG,ULONG,LPARAM); typedef PBMCALLBACKFN LPPBMCALLBACKFN; @@ -403,6 +409,7 @@ BOOL WINAPI UninstallColorProfileW(PCWSTR,PCWSTR,BOOL); BOOL WINAPI UnregisterCMMA(PCSTR,DWORD); BOOL WINAPI UnregisterCMMW(PCWSTR,DWORD); #define UnregisterCMM WINELIB_NAME_AW(UnregisterCMM) +BOOL WINAPI WcsEnumColorProfilesSize(WCS_PROFILE_MANAGEMENT_SCOPE,ENUMTYPEW*,DWORD*); BOOL WINAPI WcsGetUsePerUserProfiles(const WCHAR*,DWORD,BOOL*); #define PROFILE_FILENAME 1
1
0
0
0
Michał Janiszewski : winevulkan: Print all the arguments in make_vulkan.
by Alexandre Julliard
15 Oct '18
15 Oct '18
Module: wine Branch: master Commit: 83fd23347a7fccc85ea57c7e05cc21e432c5d5b2 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=83fd23347a7fccc85ea57c7e…
Author: Michał Janiszewski <janisozaur(a)gmail.com> Date: Fri Oct 12 00:07:54 2018 +0200 winevulkan: Print all the arguments in make_vulkan. Signed-off-by: Michał Janiszewski <janisozaur(a)gmail.com> Signed-off-by: Józef Kucia <jkucia(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/winevulkan/make_vulkan | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/winevulkan/make_vulkan b/dlls/winevulkan/make_vulkan index bd04ad4..82b4c8d 100755 --- a/dlls/winevulkan/make_vulkan +++ b/dlls/winevulkan/make_vulkan @@ -1162,7 +1162,7 @@ class VkParam(object): self._set_conversions() def __repr__(self): - return "{0} {1} {2} {3} {4}".format(self.const, self.type, self.pointer, self.name, self.array_len, self.dyn_array_len) + return "{0} {1} {2} {3} {4} {5}".format(self.const, self.type, self.pointer, self.name, self.array_len, self.dyn_array_len) @staticmethod def from_xml(param, types):
1
0
0
0
Michał Janiszewski : winevulkan: Remove duplicate format_string in make_vulkan.
by Alexandre Julliard
15 Oct '18
15 Oct '18
Module: wine Branch: master Commit: ad242e7d41fc42969afd7367f68fff3991efd697 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=ad242e7d41fc42969afd7367…
Author: Michał Janiszewski <janisozaur(a)gmail.com> Date: Fri Oct 12 00:07:53 2018 +0200 winevulkan: Remove duplicate format_string in make_vulkan. Signed-off-by: Michał Janiszewski <janisozaur(a)gmail.com> Signed-off-by: Józef Kucia <jkucia(a)codeweavers.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/winevulkan/make_vulkan | 3 --- 1 file changed, 3 deletions(-) diff --git a/dlls/winevulkan/make_vulkan b/dlls/winevulkan/make_vulkan index 65ea2ef..bd04ad4 100755 --- a/dlls/winevulkan/make_vulkan +++ b/dlls/winevulkan/make_vulkan @@ -1334,9 +1334,6 @@ class VkParam(object): return self._direction - def format_string(self): - return self.format_str - def dispatch_table(self): """ Return functions dispatch table pointer for dispatchable objects. """
1
0
0
0
Dmitry Timoshkov : kernel32: MoveFile should make sure that it has the delete access to the source file.
by Alexandre Julliard
15 Oct '18
15 Oct '18
Module: wine Branch: master Commit: f184a396a86782318886cd5b7239ebf655809033 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=f184a396a86782318886cd5b…
Author: Dmitry Timoshkov <dmitry(a)baikal.ru> Date: Sun Oct 14 10:44:40 2018 +0300 kernel32: MoveFile should make sure that it has the delete access to the source file. Signed-off-by: Dmitry Timoshkov <dmitry(a)baikal.ru> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/kernel32/path.c | 7 ++++--- dlls/kernel32/tests/file.c | 20 ++++++++------------ 2 files changed, 12 insertions(+), 15 deletions(-) diff --git a/dlls/kernel32/path.c b/dlls/kernel32/path.c index 33b2358..841a12b 100644 --- a/dlls/kernel32/path.c +++ b/dlls/kernel32/path.c @@ -1310,7 +1310,8 @@ BOOL WINAPI MoveFileWithProgressW( LPCWSTR source, LPCWSTR dest, attr.SecurityDescriptor = NULL; attr.SecurityQualityOfService = NULL; - status = NtOpenFile( &source_handle, SYNCHRONIZE, &attr, &io, 0, FILE_SYNCHRONOUS_IO_NONALERT ); + status = NtOpenFile( &source_handle, DELETE | SYNCHRONIZE, &attr, &io, + FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE, FILE_SYNCHRONOUS_IO_NONALERT ); if (status == STATUS_SUCCESS) status = wine_nt_to_unix_file_name( &nt_name, &source_unix, FILE_OPEN, FALSE ); RtlFreeUnicodeString( &nt_name ); @@ -1334,11 +1335,11 @@ BOOL WINAPI MoveFileWithProgressW( LPCWSTR source, LPCWSTR dest, SetLastError( ERROR_PATH_NOT_FOUND ); goto error; } - options = FILE_NON_DIRECTORY_FILE | FILE_SYNCHRONOUS_IO_NONALERT; if (flag & MOVEFILE_WRITE_THROUGH) options |= FILE_WRITE_THROUGH; - status = NtOpenFile( &dest_handle, GENERIC_READ | GENERIC_WRITE | SYNCHRONIZE, &attr, &io, 0, options ); + status = NtOpenFile( &dest_handle, GENERIC_READ | GENERIC_WRITE | SYNCHRONIZE, &attr, &io, + FILE_SHARE_READ | FILE_SHARE_WRITE | FILE_SHARE_DELETE, options ); if (status == STATUS_SUCCESS) /* destination exists */ { if (!(flag & MOVEFILE_REPLACE_EXISTING)) diff --git a/dlls/kernel32/tests/file.c b/dlls/kernel32/tests/file.c index 87e722b..0c99fca 100644 --- a/dlls/kernel32/tests/file.c +++ b/dlls/kernel32/tests/file.c @@ -1914,12 +1914,10 @@ static void test_MoveFileA(void) ok(hmapfile != NULL, "CreateFileMapping: error %d\n", GetLastError()); ret = MoveFileA(source, dest); - todo_wine { - ok(!ret, "MoveFileA: expected failure\n"); - ok(GetLastError() == ERROR_SHARING_VIOLATION || - broken(GetLastError() == ERROR_ACCESS_DENIED), /* Win9x and WinMe */ - "MoveFileA: expected ERROR_SHARING_VIOLATION, got %d\n", GetLastError()); - } + ok(!ret, "MoveFileA: expected failure\n"); + ok(GetLastError() == ERROR_SHARING_VIOLATION || + broken(GetLastError() == ERROR_ACCESS_DENIED), /* Win9x and WinMe */ + "MoveFileA: expected ERROR_SHARING_VIOLATION, got %d\n", GetLastError()); CloseHandle(hmapfile); CloseHandle(hfile); @@ -1934,12 +1932,10 @@ static void test_MoveFileA(void) ok(hmapfile != NULL, "CreateFileMapping: error %d\n", GetLastError()); ret = MoveFileA(source, dest); - todo_wine { - ok(!ret, "MoveFileA: expected failure\n"); - ok(GetLastError() == ERROR_SHARING_VIOLATION || - broken(GetLastError() == ERROR_ACCESS_DENIED), /* Win9x and WinMe */ - "MoveFileA: expected ERROR_SHARING_VIOLATION, got %d\n", GetLastError()); - } + ok(!ret, "MoveFileA: expected failure\n"); + ok(GetLastError() == ERROR_SHARING_VIOLATION || + broken(GetLastError() == ERROR_ACCESS_DENIED), /* Win9x and WinMe */ + "MoveFileA: expected ERROR_SHARING_VIOLATION, got %d\n", GetLastError()); CloseHandle(hmapfile); CloseHandle(hfile);
1
0
0
0
Dmitry Timoshkov : kernel32: MoveFile(source, source) should succeed.
by Alexandre Julliard
15 Oct '18
15 Oct '18
Module: wine Branch: master Commit: 7edfcd63ada3206b62f4fcee7b65d7a165a0cd9b URL:
https://source.winehq.org/git/wine.git/?a=commit;h=7edfcd63ada3206b62f4fcee…
Author: Dmitry Timoshkov <dmitry(a)baikal.ru> Date: Sun Oct 14 10:44:37 2018 +0300 kernel32: MoveFile(source, source) should succeed. Signed-off-by: Dmitry Timoshkov <dmitry(a)baikal.ru> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/kernel32/path.c | 15 ++++++++++----- dlls/kernel32/tests/file.c | 2 +- dlls/msvcp120/tests/msvcp120.c | 2 +- dlls/msvcp140/tests/msvcp140.c | 2 +- programs/cmd/tests/test_builtins.cmd.exp | 4 ++-- 5 files changed, 15 insertions(+), 10 deletions(-) diff --git a/dlls/kernel32/path.c b/dlls/kernel32/path.c index 48a3e33..33b2358 100644 --- a/dlls/kernel32/path.c +++ b/dlls/kernel32/path.c @@ -1281,7 +1281,7 @@ BOOL WINAPI MoveFileWithProgressW( LPCWSTR source, LPCWSTR dest, OBJECT_ATTRIBUTES attr; IO_STATUS_BLOCK io; NTSTATUS status; - HANDLE source_handle = 0, dest_handle; + HANDLE source_handle = 0, dest_handle = 0; ANSI_STRING source_unix, dest_unix; DWORD options; @@ -1341,18 +1341,22 @@ BOOL WINAPI MoveFileWithProgressW( LPCWSTR source, LPCWSTR dest, status = NtOpenFile( &dest_handle, GENERIC_READ | GENERIC_WRITE | SYNCHRONIZE, &attr, &io, 0, options ); if (status == STATUS_SUCCESS) /* destination exists */ { - NtClose( dest_handle ); if (!(flag & MOVEFILE_REPLACE_EXISTING)) { - SetLastError( ERROR_ALREADY_EXISTS ); - RtlFreeUnicodeString( &nt_name ); - goto error; + if (!is_same_file( source_handle, dest_handle )) + { + SetLastError( ERROR_ALREADY_EXISTS ); + RtlFreeUnicodeString( &nt_name ); + goto error; + } } else if (info.FileAttributes & FILE_ATTRIBUTE_DIRECTORY) /* cannot replace directory */ { SetLastError( ERROR_ACCESS_DENIED ); goto error; } + + NtClose( dest_handle ); } else if (status != STATUS_OBJECT_NAME_NOT_FOUND) { @@ -1412,6 +1416,7 @@ BOOL WINAPI MoveFileWithProgressW( LPCWSTR source, LPCWSTR dest, error: if (source_handle) NtClose( source_handle ); + if (dest_handle) NtClose( dest_handle ); RtlFreeAnsiString( &source_unix ); RtlFreeAnsiString( &dest_unix ); return FALSE; diff --git a/dlls/kernel32/tests/file.c b/dlls/kernel32/tests/file.c index 433a2e5..87e722b 100644 --- a/dlls/kernel32/tests/file.c +++ b/dlls/kernel32/tests/file.c @@ -1894,7 +1894,7 @@ static void test_MoveFileA(void) ok(ret != 0, "GetTempFileNameA error %d\n", GetLastError()); ret = MoveFileA(source, source); - todo_wine ok(ret, "MoveFileA: failed, error %d\n", GetLastError()); + ok(ret, "MoveFileA: failed, error %d\n", GetLastError()); ret = MoveFileA(source, dest); ok(!ret && GetLastError() == ERROR_ALREADY_EXISTS, diff --git a/dlls/msvcp120/tests/msvcp120.c b/dlls/msvcp120/tests/msvcp120.c index 2e63555..ac38aa6 100644 --- a/dlls/msvcp120/tests/msvcp120.c +++ b/dlls/msvcp120/tests/msvcp120.c @@ -1529,7 +1529,7 @@ static void test_tr2_sys__Rename(void) CloseHandle(file); ret = p_tr2_sys__Rename("tr2_test_dir\\f1", "tr2_test_dir\\f1"); - todo_wine ok(ERROR_SUCCESS == ret, "test_tr2_sys__Rename(): expect: ERROR_SUCCESS, got %d\n", ret); + ok(ERROR_SUCCESS == ret, "test_tr2_sys__Rename(): expect: ERROR_SUCCESS, got %d\n", ret); for(i=0; i<ARRAY_SIZE(tests); i++) { errno = 0xdeadbeef; if(tests[i].val == ERROR_SUCCESS) { diff --git a/dlls/msvcp140/tests/msvcp140.c b/dlls/msvcp140/tests/msvcp140.c index a3f9211..870573e 100644 --- a/dlls/msvcp140/tests/msvcp140.c +++ b/dlls/msvcp140/tests/msvcp140.c @@ -1148,7 +1148,7 @@ static void test_Rename(void) CloseHandle(file); ret = p_Rename(f1W, f1W); - todo_wine ok(ERROR_SUCCESS == ret, "_Rename(): expect: ERROR_SUCCESS, got %d\n", ret); + ok(ERROR_SUCCESS == ret, "_Rename(): expect: ERROR_SUCCESS, got %d\n", ret); for(i=0; i<ARRAY_SIZE(tests); i++) { errno = 0xdeadbeef; if(tests[i].val == ERROR_SUCCESS) { diff --git a/programs/cmd/tests/test_builtins.cmd.exp b/programs/cmd/tests/test_builtins.cmd.exp index 797a9cc..bb27c6d 100644 --- a/programs/cmd/tests/test_builtins.cmd.exp +++ b/programs/cmd/tests/test_builtins.cmd.exp @@ -1313,8 +1313,8 @@ file move succeeded @todo_wine@bar@or_broken@baz read-only files are moveable file moved in subdirectory -@todo_wine@moving a file to itself is a no-op@or_broken@moving a file to itself should be a no-op! -@todo_wine@ErrorLevel: 0@or_broken@ErrorLevel: 1 +moving a file to itself is a no-op@or_broken@moving a file to itself should be a no-op! +ErrorLevel: 0@or_broken@ErrorLevel: 1 --- directory move simple directory move succeeded moving a directory to itself gives error; errlevel 1
1
0
0
0
Dmitry Timoshkov : kernel32/tests: Move the MoveFile test where it belongs.
by Alexandre Julliard
15 Oct '18
15 Oct '18
Module: wine Branch: master Commit: b1d878fd2c709ea4b3e4b58831c5da6b66e74a62 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=b1d878fd2c709ea4b3e4b588…
Author: Dmitry Timoshkov <dmitry(a)baikal.ru> Date: Sun Oct 14 10:44:35 2018 +0300 kernel32/tests: Move the MoveFile test where it belongs. Signed-off-by: Dmitry Timoshkov <dmitry(a)baikal.ru> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/kernel32/tests/file.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/dlls/kernel32/tests/file.c b/dlls/kernel32/tests/file.c index acf657f..433a2e5 100644 --- a/dlls/kernel32/tests/file.c +++ b/dlls/kernel32/tests/file.c @@ -706,9 +706,6 @@ static void test_CopyFileA(void) ret = GetTempFileNameA(temp_path, prefix, 0, source); ok(ret != 0, "GetTempFileNameA error %d\n", GetLastError()); - ret = MoveFileA(source, source); - todo_wine ok(ret, "MoveFileA: failed, error %d\n", GetLastError()); - /* copying a file to itself must fail */ retok = CopyFileA(source, source, FALSE); ok( !retok && (GetLastError() == ERROR_SHARING_VIOLATION || broken(GetLastError() == ERROR_FILE_EXISTS) /* Win 9x */), @@ -1896,6 +1893,9 @@ static void test_MoveFileA(void) ret = GetTempFileNameA(tempdir, prefix, 0, dest); ok(ret != 0, "GetTempFileNameA error %d\n", GetLastError()); + ret = MoveFileA(source, source); + todo_wine ok(ret, "MoveFileA: failed, error %d\n", GetLastError()); + ret = MoveFileA(source, dest); ok(!ret && GetLastError() == ERROR_ALREADY_EXISTS, "MoveFileA: unexpected error %d\n", GetLastError());
1
0
0
0
Dmitry Timoshkov : kernel32/tests: Fix a bunch of access denied errors by using a dedicated TEMP directory.
by Alexandre Julliard
15 Oct '18
15 Oct '18
Module: wine Branch: master Commit: c1c0a083882aaf394671e73c3da3f0be70e72548 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=c1c0a083882aaf394671e73c…
Author: Dmitry Timoshkov <dmitry(a)baikal.ru> Date: Sun Oct 14 10:44:33 2018 +0300 kernel32/tests: Fix a bunch of access denied errors by using a dedicated TEMP directory. Signed-off-by: Dmitry Timoshkov <dmitry(a)baikal.ru> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/kernel32/tests/file.c | 21 ++++++++++++++++++--- 1 file changed, 18 insertions(+), 3 deletions(-) diff --git a/dlls/kernel32/tests/file.c b/dlls/kernel32/tests/file.c index 58ce74b..acf657f 100644 --- a/dlls/kernel32/tests/file.c +++ b/dlls/kernel32/tests/file.c @@ -62,7 +62,7 @@ static BOOL (WINAPI *pGetQueuedCompletionStatusEx)(HANDLE, OVERLAPPED_ENTRY*, UL static void (WINAPI *pRtlInitAnsiString)(PANSI_STRING,PCSZ); static void (WINAPI *pRtlFreeUnicodeString)(PUNICODE_STRING); -static const char filename[] = "testfile.xxx"; +static char filename[MAX_PATH]; static const char sillytext[] = "en larvig liten text dx \033 gx hej 84 hej 4484 ! \001\033 bla bl\na.. bla bla." "1234 43 4kljf lf &%%%&&&&&& 34 4 34 3############# 33 3 3 3 # 3## 3" @@ -457,10 +457,15 @@ static void test__lcreat( void ) if (INVALID_HANDLE_VALUE==find) ok (0, "file \"%s\" not found\n", filename); else { + const char *name = strrchr(filename, '\\'); + + if (name) name++; + else name = filename; + ret = FindClose(find); ok ( 0 != ret, "FindClose complains (%d)\n", GetLastError ()); - ok (!strcmp (filename, search_results.cFileName), - "found unexpected name \"%s\"\n", search_results.cFileName); + ok (!strcmp (name, search_results.cFileName), + "expected \"%s\", got \"%s\"\n", name, search_results.cFileName); search_results.dwFileAttributes &= ~FILE_ATTRIBUTE_NOT_CONTENT_INDEXED; search_results.dwFileAttributes &= ~FILE_ATTRIBUTE_COMPRESSED; ok (FILE_ATTRIBUTE_ARCHIVE==search_results.dwFileAttributes, @@ -5103,8 +5108,18 @@ static void test_post_completion(void) START_TEST(file) { + char temp_path[MAX_PATH]; + DWORD ret; + InitFunctionPointers(); + ret = GetTempPathA(MAX_PATH, temp_path); + ok(ret != 0, "GetTempPath error %u\n", GetLastError()); + ret = GetTempFileNameA(temp_path, "tmp", 0, filename); + ok(ret != 0, "GetTempFileName error %u\n", GetLastError()); + ret = DeleteFileA(filename); + ok(ret != 0, "DeleteFile error %u\n", GetLastError()); + test__hread( ); test__hwrite( ); test__lclose( );
1
0
0
0
← Newer
1
...
34
35
36
37
38
39
40
...
61
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
Results per page:
10
25
50
100
200