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
June
May
April
March
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
August 2019
----- 2025 -----
June 2025
May 2025
April 2025
March 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
2 participants
703 discussions
Start a n
N
ew thread
Zebediah Figura : httpapi: Stub HttpReceiveHttpRequest().
by Alexandre Julliard
19 Aug '19
19 Aug '19
Module: wine Branch: master Commit: 965cdad7c126751ef808da98b78aeee4dc23aa6c URL:
https://source.winehq.org/git/wine.git/?a=commit;h=965cdad7c126751ef808da98…
Author: Zebediah Figura <z.figura12(a)gmail.com> Date: Wed Aug 7 21:10:13 2019 -0500 httpapi: Stub HttpReceiveHttpRequest(). Signed-off-by: Zebediah Figura <z.figura12(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/httpapi/httpapi.spec | 2 +- dlls/httpapi/httpapi_main.c |
…
[View More]
11 ++ include/http.h | 263 +++++++++++++++++++++++++++++++++++++++++++- 3 files changed, 272 insertions(+), 4 deletions(-) Diff:
https://source.winehq.org/git/wine.git/?a=commitdiff;h=965cdad7c126751ef808…
[View Less]
1
0
0
0
Damjan Jovanovic : start.exe: Search PATH for the executable to launch.
by Alexandre Julliard
19 Aug '19
19 Aug '19
Module: wine Branch: master Commit: 42fa293d48be89ce06b1aab264c5c0d8cc1b4f53 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=42fa293d48be89ce06b1aab2…
Author: Damjan Jovanovic <damjan.jov(a)gmail.com> Date: Sun Aug 11 16:28:50 2019 +0200 start.exe: Search PATH for the executable to launch. We want to launch all executables through CreateProcess(), but need to provide the full path, as the searching CreateProcess() does internally when the application name is NULL is more
…
[View More]
limited: it only searches for .EXE files. Signed-off-by: Damjan Jovanovic <damjan.jov(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- programs/start/start.c | 182 +++++++++++++++++++++++++++++++++++++++++++++++-- 1 file changed, 177 insertions(+), 5 deletions(-) diff --git a/programs/start/start.c b/programs/start/start.c index b21a0c5..7668330 100644 --- a/programs/start/start.c +++ b/programs/start/start.c @@ -191,6 +191,165 @@ static void parse_title(const WCHAR *arg, WCHAR *title, int size) title[next] = '\0'; } +static BOOL search_path(const WCHAR *firstParam, WCHAR **full_path) +{ + /* Copied from WCMD_run_program() in programs/cmd/wcmdmain.c */ + +#define MAXSTRING 8192 + static const WCHAR slashW[] = {'\\','\0',}; + static const WCHAR envPath[] = {'P','A','T','H','\0'}; + static const WCHAR envPathExt[] = {'P','A','T','H','E','X','T','\0'}; + static const WCHAR dfltPathExt[] = {'.','b','a','t',';', + '.','c','o','m',';', + '.','c','m','d',';', + '.','e','x','e','\0'}; + static const WCHAR delims[] = {'/','\\',':','\0'}; + + WCHAR temp[MAX_PATH]; + WCHAR pathtosearch[MAXSTRING]; + WCHAR *pathposn; + WCHAR stemofsearch[MAX_PATH]; /* maximum allowed executable name is + MAX_PATH, including null character */ + WCHAR *lastSlash; + WCHAR pathext[MAXSTRING]; + BOOL extensionsupplied = FALSE; + DWORD len; + + /* Calculate the search path and stem to search for */ + if (wcspbrk (firstParam, delims) == NULL) { /* No explicit path given, search path */ + static const WCHAR curDir[] = {'.',';','\0'}; + lstrcpyW(pathtosearch, curDir); + len = GetEnvironmentVariableW(envPath, &pathtosearch[2], ARRAY_SIZE(pathtosearch)-2); + if ((len == 0) || (len >= ARRAY_SIZE(pathtosearch) - 2)) { + static const WCHAR curDir[] = {'.','\0'}; + lstrcpyW (pathtosearch, curDir); + } + if (wcschr(firstParam, '.') != NULL) extensionsupplied = TRUE; + if (lstrlenW(firstParam) >= MAX_PATH) { + return FALSE; + } + + lstrcpyW(stemofsearch, firstParam); + + } else { + + /* Convert eg. ..\fred to include a directory by removing file part */ + GetFullPathNameW(firstParam, ARRAY_SIZE(pathtosearch), pathtosearch, NULL); + lastSlash = wcsrchr(pathtosearch, '\\'); + if (lastSlash && wcschr(lastSlash, '.') != NULL) extensionsupplied = TRUE; + lstrcpyW(stemofsearch, lastSlash+1); + + /* Reduce pathtosearch to a path with trailing '\' to support c:\a.bat and + c:\windows\a.bat syntax */ + if (lastSlash) *(lastSlash + 1) = 0x00; + } + + /* Now extract PATHEXT */ + len = GetEnvironmentVariableW(envPathExt, pathext, ARRAY_SIZE(pathext)); + if ((len == 0) || (len >= ARRAY_SIZE(pathext))) { + lstrcpyW (pathext, dfltPathExt); + } + + /* Loop through the search path, dir by dir */ + pathposn = pathtosearch; + WINE_TRACE("Searching in '%s' for '%s'\n", wine_dbgstr_w(pathtosearch), + wine_dbgstr_w(stemofsearch)); + while (pathposn) { + WCHAR thisDir[MAX_PATH] = {'\0'}; + int length = 0; + WCHAR *pos = NULL; + BOOL found = FALSE; + BOOL inside_quotes = FALSE; + + /* Work on the first directory on the search path */ + pos = pathposn; + while ((inside_quotes || *pos != ';') && *pos != 0) + { + if (*pos == '"') + inside_quotes = !inside_quotes; + pos++; + } + + if (*pos) { /* Reached semicolon */ + memcpy(thisDir, pathposn, (pos-pathposn) * sizeof(WCHAR)); + thisDir[(pos-pathposn)] = 0x00; + pathposn = pos+1; + } else { /* Reached string end */ + lstrcpyW(thisDir, pathposn); + pathposn = NULL; + } + + /* Remove quotes */ + length = lstrlenW(thisDir); + if (thisDir[length - 1] == '"') + thisDir[length - 1] = 0; + + if (*thisDir != '"') + lstrcpyW(temp, thisDir); + else + lstrcpyW(temp, thisDir + 1); + + /* Since you can have eg. ..\.. on the path, need to expand + to full information */ + GetFullPathNameW(temp, MAX_PATH, thisDir, NULL); + + /* 1. If extension supplied, see if that file exists */ + lstrcatW(thisDir, slashW); + lstrcatW(thisDir, stemofsearch); + pos = &thisDir[lstrlenW(thisDir)]; /* Pos = end of name */ + + /* 1. If extension supplied, see if that file exists */ + if (extensionsupplied) { + if (GetFileAttributesW(thisDir) != INVALID_FILE_ATTRIBUTES) { + found = TRUE; + } + } + + /* 2. Any .* matches? */ + if (!found) { + HANDLE h; + WIN32_FIND_DATAW finddata; + static const WCHAR allFiles[] = {'.','*','\0'}; + + lstrcatW(thisDir,allFiles); + h = FindFirstFileW(thisDir, &finddata); + FindClose(h); + if (h != INVALID_HANDLE_VALUE) { + + WCHAR *thisExt = pathext; + + /* 3. Yes - Try each path ext */ + while (thisExt) { + WCHAR *nextExt = wcschr(thisExt, ';'); + + if (nextExt) { + memcpy(pos, thisExt, (nextExt-thisExt) * sizeof(WCHAR)); + pos[(nextExt-thisExt)] = 0x00; + thisExt = nextExt+1; + } else { + lstrcpyW(pos, thisExt); + thisExt = NULL; + } + + if (GetFileAttributesW(thisDir) != INVALID_FILE_ATTRIBUTES) { + found = TRUE; + thisExt = NULL; + } + } + } + } + + if (found) { + int needed_size = lstrlenW(thisDir) + 1; + *full_path = HeapAlloc(GetProcessHeap(), 0, needed_size * sizeof(WCHAR)); + if (*full_path) + lstrcpyW(*full_path, thisDir); + return TRUE; + } + } + return FALSE; +} + int wmain (int argc, WCHAR *argv[]) { SHELLEXECUTEINFOW sei; @@ -200,7 +359,9 @@ int wmain (int argc, WCHAR *argv[]) BOOL unix_mode = FALSE; BOOL progid_open = FALSE; WCHAR *title = NULL; + const WCHAR *file; WCHAR *dos_filename = NULL; + WCHAR *fullpath = NULL; WCHAR *parent_directory = NULL; DWORD binary_type; @@ -359,10 +520,10 @@ int wmain (int argc, WCHAR *argv[]) if (i == argc) { if (progid_open || unix_mode) usage(); - sei.lpFile = cmdW; + file = cmdW; } else - sei.lpFile = argv[i++]; + file = argv[i++]; args = build_args( argc - i, &argv[i] ); sei.lpParameters = args; @@ -377,10 +538,10 @@ int wmain (int argc, WCHAR *argv[]) if (!wine_get_dos_file_name_ptr) fatal_string(STRING_UNIXFAIL); - multibyte_unixpath_len = WideCharToMultiByte(CP_UNIXCP, 0, sei.lpFile, -1, NULL, 0, NULL, NULL); + multibyte_unixpath_len = WideCharToMultiByte(CP_UNIXCP, 0, file, -1, NULL, 0, NULL, NULL); multibyte_unixpath = HeapAlloc(GetProcessHeap(), 0, multibyte_unixpath_len); - WideCharToMultiByte(CP_UNIXCP, 0, sei.lpFile, -1, multibyte_unixpath, multibyte_unixpath_len, NULL, NULL); + WideCharToMultiByte(CP_UNIXCP, 0, file, -1, multibyte_unixpath, multibyte_unixpath_len, NULL, NULL); dos_filename = wine_get_dos_file_name_ptr(multibyte_unixpath); @@ -393,6 +554,16 @@ int wmain (int argc, WCHAR *argv[]) if (!sei.lpDirectory) sei.lpDirectory = parent_directory = get_parent_dir(dos_filename); sei.fMask &= ~SEE_MASK_FLAG_NO_UI; + } else { + if (search_path(file, &fullpath)) { + if (fullpath != NULL) { + sei.lpFile = fullpath; + } else { + fatal_string_error(STRING_EXECFAIL, ERROR_OUTOFMEMORY, file); + } + } else { + sei.lpFile = file; + } } if (GetBinaryTypeW(sei.lpFile, &binary_type)) { @@ -413,7 +584,7 @@ int wmain (int argc, WCHAR *argv[]) startup_info.lpTitle = title; if (!CreateProcessW( - NULL, /* lpApplicationName */ + sei.lpFile, /* lpApplicationName */ commandline, /* lpCommandLine */ NULL, /* lpProcessAttributes */ NULL, /* lpThreadAttributes */ @@ -484,6 +655,7 @@ int wmain (int argc, WCHAR *argv[]) done: HeapFree( GetProcessHeap(), 0, args ); HeapFree( GetProcessHeap(), 0, dos_filename ); + HeapFree( GetProcessHeap(), 0, fullpath ); HeapFree( GetProcessHeap(), 0, parent_directory ); HeapFree( GetProcessHeap(), 0, title );
[View Less]
1
0
0
0
Damjan Jovanovic : start.exe: Launch all binaries through CreateProcess().
by Alexandre Julliard
19 Aug '19
19 Aug '19
Module: wine Branch: master Commit: 3c7501e8f0f941db012bed16cf7b5943202fe83d URL:
https://source.winehq.org/git/wine.git/?a=commit;h=3c7501e8f0f941db012bed16…
Author: Damjan Jovanovic <damjan.jov(a)gmail.com> Date: Sun Aug 11 16:28:45 2019 +0200 start.exe: Launch all binaries through CreateProcess(). This lets us pass them the title, priority classes, and other options unsupported by ShellExecuteEx(). Signed-off-by: Damjan Jovanovic <damjan.jov(a)gmail.com> Signed-off-by:
…
[View More]
Alexandre Julliard <julliard(a)winehq.org> --- programs/start/start.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/programs/start/start.c b/programs/start/start.c index bc5b203..b21a0c5 100644 --- a/programs/start/start.c +++ b/programs/start/start.c @@ -393,8 +393,9 @@ int wmain (int argc, WCHAR *argv[]) if (!sei.lpDirectory) sei.lpDirectory = parent_directory = get_parent_dir(dos_filename); sei.fMask &= ~SEE_MASK_FLAG_NO_UI; + } - if (GetBinaryTypeW(sei.lpFile, &binary_type)) { + if (GetBinaryTypeW(sei.lpFile, &binary_type)) { WCHAR *commandline; STARTUPINFOW startup_info; PROCESS_INFORMATION process_information; @@ -427,8 +428,7 @@ int wmain (int argc, WCHAR *argv[]) } sei.hProcess = process_information.hProcess; goto done; - } - } + } if (!ShellExecuteExW(&sei)) {
[View Less]
1
0
0
0
Damjan Jovanovic : start.exe: Pass the "show window" flags to CreateProcess() too.
by Alexandre Julliard
19 Aug '19
19 Aug '19
Module: wine Branch: master Commit: f2fa7ec3c57dc79fab755f6a0ec0c43447fce915 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=f2fa7ec3c57dc79fab755f6a…
Author: Damjan Jovanovic <damjan.jov(a)gmail.com> Date: Sun Aug 11 16:28:37 2019 +0200 start.exe: Pass the "show window" flags to CreateProcess() too. Signed-off-by: Damjan Jovanovic <damjan.jov(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- programs/start/start.c | 1 + 1 file
…
[View More]
changed, 1 insertion(+) diff --git a/programs/start/start.c b/programs/start/start.c index 1bdcba9..bc5b203 100644 --- a/programs/start/start.c +++ b/programs/start/start.c @@ -408,6 +408,7 @@ int wmain (int argc, WCHAR *argv[]) ZeroMemory(&startup_info, sizeof(startup_info)); startup_info.cb = sizeof(startup_info); + startup_info.wShowWindow = sei.nShow; startup_info.lpTitle = title; if (!CreateProcessW(
[View Less]
1
0
0
0
Damjan Jovanovic : cmd.exe: If there is a title given through STARTUPINFO, use it.
by Alexandre Julliard
19 Aug '19
19 Aug '19
Module: wine Branch: master Commit: ada8b1ab9387f0ee2a6b96ce7c468934ef3d86c0 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=ada8b1ab9387f0ee2a6b96ce…
Author: Damjan Jovanovic <damjan.jov(a)gmail.com> Date: Sun Aug 11 16:28:33 2019 +0200 cmd.exe: If there is a title given through STARTUPINFO, use it. Signed-off-by: Damjan Jovanovic <damjan.jov(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- programs/cmd/wcmdmain.c | 7 ++++++- 1
…
[View More]
file changed, 6 insertions(+), 1 deletion(-) diff --git a/programs/cmd/wcmdmain.c b/programs/cmd/wcmdmain.c index 29e498a..d7c0ce1 100644 --- a/programs/cmd/wcmdmain.c +++ b/programs/cmd/wcmdmain.c @@ -2417,6 +2417,7 @@ int wmain (int argc, WCHAR *argvW[]) CMD_LIST *toExecute = NULL; /* Commands left to be executed */ OSVERSIONINFOW osv; char osver[50]; + STARTUPINFOW startupInfo; if (!GetEnvironmentVariableW(comspecW, comspec, ARRAY_SIZE(comspec))) { @@ -2676,7 +2677,11 @@ int wmain (int argc, WCHAR *argvW[]) return errorlevel; } - SetConsoleTitleW(WCMD_LoadMessage(WCMD_CONSTITLE)); + GetStartupInfoW(&startupInfo); + if (startupInfo.lpTitle != NULL) + SetConsoleTitleW(startupInfo.lpTitle); + else + SetConsoleTitleW(WCMD_LoadMessage(WCMD_CONSTITLE)); /* Note: cmd.exe /c dir does not get a new color, /k dir does */ if (opt_t) {
[View Less]
1
0
0
0
Damjan Jovanovic : start.exe: Unquote the title.
by Alexandre Julliard
19 Aug '19
19 Aug '19
Module: wine Branch: master Commit: 6ae919de8112483c3e4c1b0cd69e0de6f084d038 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=6ae919de8112483c3e4c1b0c…
Author: Damjan Jovanovic <damjan.jov(a)gmail.com> Date: Sun Aug 11 16:28:26 2019 +0200 start.exe: Unquote the title. Signed-off-by: Damjan Jovanovic <damjan.jov(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- programs/start/start.c | 30 +++++++++++++++++++++++++++++- 1 file changed,
…
[View More]
29 insertions(+), 1 deletion(-) diff --git a/programs/start/start.c b/programs/start/start.c index 18fd5f5..1bdcba9 100644 --- a/programs/start/start.c +++ b/programs/start/start.c @@ -172,6 +172,25 @@ static BOOL is_option(const WCHAR* arg, const WCHAR* opt) arg, -1, opt, -1) == CSTR_EQUAL; } +static void parse_title(const WCHAR *arg, WCHAR *title, int size) +{ + /* See: + * WCMD_start() in programs/cmd/builtins.c + * WCMD_parameter_with_delims() in programs/cmd/batch.c + * The shell has already tokenized the command line for us. + * All we need to do is filter out all the quotes. + */ + + int next; + const WCHAR *p = arg; + + for (next = 0; next < (size-1) && *p; p++) { + if (*p != '"') + title[next++] = *p; + } + title[next] = '\0'; +} + int wmain (int argc, WCHAR *argv[]) { SHELLEXECUTEINFOW sei; @@ -223,7 +242,15 @@ int wmain (int argc, WCHAR *argv[]) for (i=1; i<argc; i++) { /* parse first quoted argument as console title */ if (!title && argv[i][0] == '"') { - title = argv[i]; + /* it will remove at least 1 quote */ + int maxChars = lstrlenW(argv[1]); + title = HeapAlloc(GetProcessHeap(), 0, maxChars*sizeof(WCHAR)); + if (title) + parse_title(argv[i], title, maxChars); + else { + WINE_ERR("out of memory\n"); + ExitProcess(1); + } continue; } if (argv[i][0] != '/') @@ -457,6 +484,7 @@ done: HeapFree( GetProcessHeap(), 0, args ); HeapFree( GetProcessHeap(), 0, dos_filename ); HeapFree( GetProcessHeap(), 0, parent_directory ); + HeapFree( GetProcessHeap(), 0, title ); if (sei.fMask & SEE_MASK_NOCLOSEPROCESS) { DWORD exitcode;
[View Less]
1
0
0
0
Sven Baars : msvfw32/tests: Add MCIWndCreate tests.
by Alexandre Julliard
19 Aug '19
19 Aug '19
Module: wine Branch: master Commit: e1049b671d9618e831ec901010bafbd8357ef99e URL:
https://source.winehq.org/git/wine.git/?a=commit;h=e1049b671d9618e831ec9010…
Author: Sven Baars <sven.wine(a)gmail.com> Date: Sat Aug 17 18:50:15 2019 +0200 msvfw32/tests: Add MCIWndCreate tests. Signed-off-by: Sven Baars <sven.wine(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/msvfw32/tests/Makefile.in | 3 +- dlls/msvfw32/tests/mciwnd.c | 203 +++
…
[View More]
++++++++++++++++++++++++++++++++++++++ 2 files changed, 205 insertions(+), 1 deletion(-) diff --git a/dlls/msvfw32/tests/Makefile.in b/dlls/msvfw32/tests/Makefile.in index ecb26db..01d83ac 100644 --- a/dlls/msvfw32/tests/Makefile.in +++ b/dlls/msvfw32/tests/Makefile.in @@ -1,8 +1,9 @@ TESTDLL = msvfw32.dll -IMPORTS = msvfw32 advapi32 gdi32 +IMPORTS = msvfw32 advapi32 gdi32 user32 C_SRCS = \ drawdib.c \ + mciwnd.c \ msvfw.c RC_SRCS = \ diff --git a/dlls/msvfw32/tests/mciwnd.c b/dlls/msvfw32/tests/mciwnd.c new file mode 100644 index 0000000..27ca2e8 --- /dev/null +++ b/dlls/msvfw32/tests/mciwnd.c @@ -0,0 +1,203 @@ +/* + * Unit tests for MCIWnd + * + * Copyright 2019 Sven Baars + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 2.1 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA + */ + +#define WIN32_LEAN_AND_MEAN + +#include <windows.h> +#include <vfw.h> + +#include "wine/heap.h" +#include "wine/test.h" + +static const DWORD file_header[] = /* file_header */ +{ + FOURCC_RIFF, 0x8c0 /* file size */, + formtypeAVI, + FOURCC_LIST, 0xc0 /* list length */, + listtypeAVIHEADER, ckidAVIMAINHDR, sizeof(MainAVIHeader), +}; + +static const MainAVIHeader main_avi_header = +{ + 0x0001046b, /* dwMicroSecPerFrame */ + 0x00000000, /* dwMaxBytesPerSec */ + 0x00000000, /* dwPaddingGranularity */ + 0x00000810, /* dwFlags */ + 2, /* dwTotalFrames */ + 0, /* dwInitialFrames */ + 1, /* dwStreams */ + 0x48, /* dwSuggestedBufferSize*/ + 5, /* dwWidth */ + 5, /* dwHeight */ + { 0, 0, 0, 0 } /* dwReserved[4] */ +}; + +static const DWORD stream_list[] = +{ + FOURCC_LIST, 0x74 /* length */, + listtypeSTREAMHEADER, ckidSTREAMHEADER, 0x38 /* length */, +}; + +static const AVIStreamHeader avi_stream_header = +{ + streamtypeVIDEO, /* fccType */ + 0, /* fccHandler */ + 0, /* dwFlags */ + 0, /* wPriority */ + 0, /* wLanguage */ + 0, /* dwInitialFrames */ + 1, /* dwScale */ + 0xf, /* dwRate */ + 0, /* dwStart */ + 2, /* dwLength */ + 0x48, /* dwSuggestedBufferSize*/ + 0, /* dwQuality */ + 0, /* dwSampleSize */ + { 0, 0, 0, 0 } /* short left right top bottom */ +}; + +static const DWORD video_stream_format[] = +{ + ckidSTREAMFORMAT, + 0x28 /* length */, + 0x28 /* length */, + 5 /* width */, + 5 /* height */, + 0x00180001 , + mmioFOURCC('c', 'v', 'i', 'd'), + 0x245a, + 0, 0, 0, 0, +}; + +static const DWORD padding[] = +{ + ckidAVIPADDING, 0x718 /* length */, +}; + +static const DWORD data[] = +{ + FOURCC_LIST, 0xa4 /* length */, listtypeAVIMOVIE, + mmioFOURCC('0', '0', 'd', 'b'), 0x48, 0x48000000, 0x08000800, + 0x00100100, 0x00003e00, 0x08000000, 0x00200800, + 0x00001600, 0x00000000, 0x00003a00, 0x22e306f9, + 0xfc120000, 0x0a000022, 0x00000000, 0x00300000, + 0x00c01200, 0x00000000, 0x02010000, 0x00000000, + mmioFOURCC('0', '0', 'd', 'b'), 0x48, 0x48000000, 0x08000800, + 0x00100100, 0x00003e00, 0x08000000, 0x00200800, + 0x00001600, 0x00000000, 0x00003a00, 0x22e306f9, + 0xfc120000, 0x0a000022, 0x00000000, 0x00300000, + 0x00c01200, 0x00000000, 0x02010000, 0x00000000, + mmioFOURCC('i', 'd', 'x', '1'), 0x20, mmioFOURCC('0', '0', 'd', 'b'), 0x10, + 0x04, 0x48, mmioFOURCC('0', '0', 'd', 'b'), 0x10, + 0x54, 0x48, +}; + +static BOOL create_avi_file(char *fname) +{ + HANDLE hFile; + DWORD written; + char temp_path[MAX_PATH]; + BOOL ret; + BYTE *buffer; + ULONG buffer_length; + + ret = GetTempPathA(sizeof(temp_path), temp_path); + ok(ret, "Failed to get a temp path, err %d\n", GetLastError()); + if (!ret) + return FALSE; + + ret = GetTempFileNameA(temp_path, "mci", 0, fname); + ok(ret, "Failed to get a temp name, err %d\n", GetLastError()); + if (!ret) + return FALSE; + DeleteFileA(fname); + + lstrcatA(fname, ".avi"); + + hFile = CreateFileA(fname, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL); + ok(hFile != INVALID_HANDLE_VALUE, "Failed to create a file, err %d\n", GetLastError()); + if (hFile == INVALID_HANDLE_VALUE) return FALSE; + + buffer_length = padding[1]; + buffer = heap_alloc_zero(buffer_length); + + WriteFile(hFile, file_header, sizeof(file_header), &written, NULL); + WriteFile(hFile, &main_avi_header, sizeof(MainAVIHeader), &written, NULL); + WriteFile(hFile, stream_list, sizeof(stream_list), &written, NULL); + WriteFile(hFile, &avi_stream_header, sizeof(AVIStreamHeader), &written, NULL); + WriteFile(hFile, video_stream_format, sizeof(video_stream_format), &written, NULL); + WriteFile(hFile, padding, sizeof(padding), &written, NULL); + WriteFile(hFile, buffer, buffer_length, &written, NULL); + WriteFile(hFile, data, sizeof(data), &written, NULL); + + heap_free(buffer); + + CloseHandle(hFile); + return ret; +} + +static void test_MCIWndCreate(void) +{ + HWND parent, window; + HMODULE hinst = GetModuleHandleA(NULL); + char fname[MAX_PATH]; + char invalid_fname[] = "invalid.avi"; + char error[200]; + LRESULT ret; + + create_avi_file(fname); + + window = MCIWndCreateA(NULL, hinst, MCIWNDF_NOERRORDLG, fname); + ok(window != NULL, "Failed to create an MCIWnd window without parent\n"); + + ret = SendMessageA(window, MCIWNDM_GETERRORA, sizeof(error), (LPARAM)error); + ok(!ret || broken(ret == ERROR_INVALID_HANDLE) /* w2003std, w2008s64 */, + "Unexpected error %ld\n", ret); + + DestroyWindow(window); + + parent = CreateWindowExA(0, "static", "msvfw32 test", + WS_POPUP, 0, 0, 100, 100, + 0, 0, 0, NULL); + ok(parent != NULL, "Failed to create a window\n"); + window = MCIWndCreateA(parent, hinst, MCIWNDF_NOERRORDLG, fname); + ok(window != NULL, "Failed to create an MCIWnd window\n"); + + ret = SendMessageA(window, MCIWNDM_GETERRORA, sizeof(error), (LPARAM)error); + ok(!ret || broken(ret == ERROR_INVALID_HANDLE) /* w2003std, w2008s64 */, + "Unexpected error %ld\n", ret); + + DestroyWindow(parent); + + window = MCIWndCreateA(NULL, hinst, MCIWNDF_NOERRORDLG, invalid_fname); + ok(window != NULL, "Failed to create an MCIWnd window\n"); + + ret = SendMessageA(window, MCIWNDM_GETERRORA, sizeof(error), (LPARAM)error); + todo_wine ok(ret == MCIERR_FILE_NOT_FOUND, "Unexpected error %ld\n", ret); + + DestroyWindow(window); + + DeleteFileA(fname); +} + +START_TEST(mciwnd) +{ + test_MCIWndCreate(); +}
[View Less]
1
0
0
0
Akihiro Sagawa : winex11.drv: Indicate whether the drop point is non-client area.
by Alexandre Julliard
19 Aug '19
19 Aug '19
Module: wine Branch: master Commit: aaac4e25ab10f6d27047917d21fe74888387b2ce URL:
https://source.winehq.org/git/wine.git/?a=commit;h=aaac4e25ab10f6d27047917d…
Author: Akihiro Sagawa <sagawa.aki(a)gmail.com> Date: Thu Aug 15 22:06:33 2019 +0900 winex11.drv: Indicate whether the drop point is non-client area. Signed-off-by: Akihiro Sagawa <sagawa.aki(a)gmail.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/winex11.drv/xdnd.c | 5 ++++- 1 file
…
[View More]
changed, 4 insertions(+), 1 deletion(-) diff --git a/dlls/winex11.drv/xdnd.c b/dlls/winex11.drv/xdnd.c index 1f7f0d9..8dc4a5b 100644 --- a/dlls/winex11.drv/xdnd.c +++ b/dlls/winex11.drv/xdnd.c @@ -636,12 +636,15 @@ static HRESULT X11DRV_XDND_SendDropFiles(HWND hwnd) HGLOBAL dropHandle = GlobalAlloc(GMEM_FIXED, GlobalSize(current->contents)); if (dropHandle) { + RECT rect; DROPFILES *lpDrop = GlobalLock(dropHandle); memcpy(lpDrop, GlobalLock(current->contents), GlobalSize(current->contents)); GlobalUnlock(current->contents); lpDrop->pt.x = XDNDxy.x; lpDrop->pt.y = XDNDxy.y; - lpDrop->fNC = !ScreenToClient(hwnd, &lpDrop->pt); + lpDrop->fNC = !(ScreenToClient(hwnd, &lpDrop->pt) && + GetClientRect(hwnd, &rect) && + PtInRect(&rect, lpDrop->pt)); TRACE("Sending WM_DROPFILES: hWnd=0x%p, fNC=%d, x=%d, y=%d, files=%p(%s)\n", hwnd, lpDrop->fNC, lpDrop->pt.x, lpDrop->pt.y, ((char*)lpDrop) + lpDrop->pFiles, debugstr_w((WCHAR*)(((char*)lpDrop) + lpDrop->pFiles)));
[View Less]
1
0
0
0
Gleb Smirnoff : iphlpapi: Account for structs inpcb and tcpcb being unavailable for userland in FreeBSD 12.
by Alexandre Julliard
19 Aug '19
19 Aug '19
Module: wine Branch: master Commit: 424e1e71cac268cc2db8483d84474f88d61b67d1 URL:
https://source.winehq.org/git/wine.git/?a=commit;h=424e1e71cac268cc2db8483d…
Author: Gleb Smirnoff <glebius(a)FreeBSD.org> Date: Sat Aug 17 10:32:31 2019 +0200 iphlpapi: Account for structs inpcb and tcpcb being unavailable for userland in FreeBSD 12. FreeBSD 12, specifically __FreeBSD_version 1200026 and later, no longer exposes struct inpcb and struct tcpcb to userland. New structs xinpcb and
…
[View More]
xtcpcb shall be used instead. Signed-off-by: Gerald Pfeifer <gerald(a)pfeifer.com> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/iphlpapi/ipstats.c | 28 ++++++++++++++++------------ 1 file changed, 16 insertions(+), 12 deletions(-) diff --git a/dlls/iphlpapi/ipstats.c b/dlls/iphlpapi/ipstats.c index 0b762eb..5a52753 100644 --- a/dlls/iphlpapi/ipstats.c +++ b/dlls/iphlpapi/ipstats.c @@ -2226,13 +2226,15 @@ DWORD build_tcp_table( TCP_TABLE_CLASS class, void **tablep, BOOL order, HANDLE pXIG->xig_len > sizeof (struct xinpgen); pXIG = (struct xinpgen *)((char *)pXIG + pXIG->xig_len)) { - struct tcpcb *pTCPData = NULL; - struct inpcb *pINData; - struct xsocket *pSockData; - - pTCPData = &((struct xtcpcb *)pXIG)->xt_tp; - pINData = &((struct xtcpcb *)pXIG)->xt_inp; - pSockData = &((struct xtcpcb *)pXIG)->xt_socket; +#if __FreeBSD_version >= 1200026 + struct xtcpcb *pTCPData = (struct xtcpcb *)pXIG; + struct xinpcb *pINData = &pTCPData->xt_inp; + struct xsocket *pSockData = &pINData->xi_socket; +#else + struct tcpcb *pTCPData = &((struct xtcpcb *)pXIG)->xt_tp; + struct inpcb *pINData = &((struct xtcpcb *)pXIG)->xt_inp; + struct xsocket *pSockData = &((struct xtcpcb *)pXIG)->xt_socket; +#endif /* Ignore sockets for other protocols */ if (pSockData->xso_protocol != IPPROTO_TCP) @@ -2538,11 +2540,13 @@ DWORD build_udp_table( UDP_TABLE_CLASS class, void **tablep, BOOL order, HANDLE pXIG->xig_len > sizeof (struct xinpgen); pXIG = (struct xinpgen *)((char *)pXIG + pXIG->xig_len)) { - struct inpcb *pINData; - struct xsocket *pSockData; - - pINData = &((struct xinpcb *)pXIG)->xi_inp; - pSockData = &((struct xinpcb *)pXIG)->xi_socket; +#if __FreeBSD_version >= 1200026 + struct xinpcb *pINData = (struct xinpcb *)pXIG; + struct xsocket *pSockData = &pINData->xi_socket; +#else + struct inpcb *pINData = &((struct xinpcb *)pXIG)->xi_inp; + struct xsocket *pSockData = &((struct xinpcb *)pXIG)->xi_socket; +#endif /* Ignore sockets for other protocols */ if (pSockData->xso_protocol != IPPROTO_UDP)
[View Less]
1
0
0
0
Richard Yao : advapi32: Add EventWriteString stub.
by Alexandre Julliard
19 Aug '19
19 Aug '19
Module: wine Branch: master Commit: 8d5554247338acdb3ed94668115f73be667378fd URL:
https://source.winehq.org/git/wine.git/?a=commit;h=8d5554247338acdb3ed94668…
Author: Richard Yao <ryao(a)gentoo.org> Date: Sun Aug 18 19:14:30 2019 -0400 advapi32: Add EventWriteString stub. "Are You Ready for Valve Index?" needs this to work. Signed-off-by: Richard Yao <ryao(a)gentoo.org> Signed-off-by: Alexandre Julliard <julliard(a)winehq.org> --- dlls/advapi32/advapi32.spec
…
[View More]
| 2 +- .../api-ms-win-downlevel-advapi32-l1-1-0.spec | 2 +- .../api-ms-win-eventing-provider-l1-1-0.spec | 2 +- dlls/kernelbase/kernelbase.spec | 2 +- dlls/ntdll/misc.c | 10 ++++++++++ 5 files changed, 14 insertions(+), 4 deletions(-) diff --git a/dlls/advapi32/advapi32.spec b/dlls/advapi32/advapi32.spec index 231ab05..3db5612 100644 --- a/dlls/advapi32/advapi32.spec +++ b/dlls/advapi32/advapi32.spec @@ -297,7 +297,7 @@ # @ stub EventWriteEndScenario # @ stub EventWriteEx # @ stub EventWriteStartScenario -# @ stub EventWriteString +@ stdcall EventWriteString(int64 long int64 ptr) ntdll.EtwEventWriteString @ stdcall EventWriteTransfer(int64 ptr ptr ptr long ptr) ntdll.EtwEventWriteTransfer @ stdcall FileEncryptionStatusA(str ptr) @ stdcall FileEncryptionStatusW(wstr ptr) diff --git a/dlls/api-ms-win-downlevel-advapi32-l1-1-0/api-ms-win-downlevel-advapi32-l1-1-0.spec b/dlls/api-ms-win-downlevel-advapi32-l1-1-0/api-ms-win-downlevel-advapi32-l1-1-0.spec index b2dcc17..579811b 100644 --- a/dlls/api-ms-win-downlevel-advapi32-l1-1-0/api-ms-win-downlevel-advapi32-l1-1-0.spec +++ b/dlls/api-ms-win-downlevel-advapi32-l1-1-0/api-ms-win-downlevel-advapi32-l1-1-0.spec @@ -44,7 +44,7 @@ @ stdcall EventRegister(ptr ptr ptr ptr) advapi32.EventRegister @ stdcall EventUnregister(int64) advapi32.EventUnregister @ stdcall EventWrite(int64 ptr long ptr) advapi32.EventWrite -@ stub EventWriteString +@ stdcall EventWriteString(int64 long int64 ptr) advapi32.EventWriteString @ stdcall EventWriteTransfer(int64 ptr ptr ptr long ptr) advapi32.EventWriteTransfer @ stdcall FindFirstFreeAce(ptr ptr) advapi32.FindFirstFreeAce @ stdcall FreeSid(ptr) advapi32.FreeSid diff --git a/dlls/api-ms-win-eventing-provider-l1-1-0/api-ms-win-eventing-provider-l1-1-0.spec b/dlls/api-ms-win-eventing-provider-l1-1-0/api-ms-win-eventing-provider-l1-1-0.spec index bd4e7a3..92d495c 100644 --- a/dlls/api-ms-win-eventing-provider-l1-1-0/api-ms-win-eventing-provider-l1-1-0.spec +++ b/dlls/api-ms-win-eventing-provider-l1-1-0/api-ms-win-eventing-provider-l1-1-0.spec @@ -6,5 +6,5 @@ @ stdcall EventUnregister(int64) advapi32.EventUnregister @ stdcall EventWrite(int64 ptr long ptr) advapi32.EventWrite @ stub EventWriteEx -@ stub EventWriteString +@ stdcall EventWriteString(int64 long int64 ptr) advapi32.EventWriteString @ stdcall EventWriteTransfer(int64 ptr ptr ptr long ptr) advapi32.EventWriteTransfer diff --git a/dlls/kernelbase/kernelbase.spec b/dlls/kernelbase/kernelbase.spec index 4bb2b55..7021447 100644 --- a/dlls/kernelbase/kernelbase.spec +++ b/dlls/kernelbase/kernelbase.spec @@ -335,7 +335,7 @@ @ stdcall EventUnregister(int64) ntdll.EtwEventUnregister @ stdcall EventWrite(int64 ptr long ptr) ntdll.EtwEventWrite # @ stub EventWriteEx -# @ stub EventWriteString +@ stdcall EventWriteString(int64 long int64 ptr) ntdll.EtwEventWriteString @ stdcall EventWriteTransfer(int64 ptr ptr ptr long ptr) ntdll.EtwEventWriteTransfer @ stdcall ExitProcess(long) ntdll.RtlExitUserProcess @ stdcall ExitThread(long) ntdll.RtlExitUserThread diff --git a/dlls/ntdll/misc.c b/dlls/ntdll/misc.c index 152b2cf..2a13551 100644 --- a/dlls/ntdll/misc.c +++ b/dlls/ntdll/misc.c @@ -427,6 +427,16 @@ ULONG WINAPI EtwEventSetInformation( REGHANDLE handle, EVENT_INFO_CLASS class, v } /****************************************************************************** + * EtwEventWriteString (NTDLL.@) + */ +ULONG WINAPI EtwEventWriteString( REGHANDLE handle, UCHAR level, ULONGLONG keyword, PCWSTR string ) +{ + FIXME("%s, %u, %s, %s: stub\n", wine_dbgstr_longlong(handle), level, + wine_dbgstr_longlong(keyword), debugstr_w(string)); + return ERROR_SUCCESS; +} + +/****************************************************************************** * EtwEventWriteTransfer (NTDLL.@) */ ULONG WINAPI EtwEventWriteTransfer( REGHANDLE handle, PCEVENT_DESCRIPTOR descriptor, LPCGUID activity,
[View Less]
1
0
0
0
← Newer
1
...
29
30
31
32
33
34
35
...
71
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
62
63
64
65
66
67
68
69
70
71
Results per page:
10
25
50
100
200