ReactOS.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
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
List overview
Download
Ros-diffs
July 2016
----- 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
ros-diffs@reactos.org
18 participants
358 discussions
Start a n
N
ew thread
[mjansen] 71956: [EXPLORER] Fix the Explore all users/open all users menu items. Patch by Jared Smudde. CORE-11146 #resolve #comment Thanks!
by mjansen@svn.reactos.org
Author: mjansen Date: Sat Jul 16 17:49:27 2016 New Revision: 71956 URL:
http://svn.reactos.org/svn/reactos?rev=71956&view=rev
Log: [EXPLORER] Fix the Explore all users/open all users menu items. Patch by Jared Smudde. CORE-11146 #resolve #comment Thanks! Modified: trunk/reactos/base/shell/explorer/traywnd.cpp Modified: trunk/reactos/base/shell/explorer/traywnd.cpp URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/explorer/traywn…
============================================================================== --- trunk/reactos/base/shell/explorer/traywnd.cpp [iso-8859-1] (original) +++ trunk/reactos/base/shell/explorer/traywnd.cpp [iso-8859-1] Sat Jul 16 17:49:27 2016 @@ -1704,9 +1704,9 @@ { ShellExecute(hWndOwner, lpOperation, + szDir, NULL, NULL, - szDir, SW_SHOWNORMAL); } }
8 years, 5 months
1
0
0
0
[ekohl] 71955: Ooops! These were not meant to be committed!
by ekohl@svn.reactos.org
Author: ekohl Date: Sat Jul 16 17:41:44 2016 New Revision: 71955 URL:
http://svn.reactos.org/svn/reactos?rev=71955&view=rev
Log: Ooops! These were not meant to be committed! Modified: trunk/reactos/base/system/services/database.c Modified: trunk/reactos/base/system/services/database.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/system/services/datab…
============================================================================== --- trunk/reactos/base/system/services/database.c [iso-8859-1] (original) +++ trunk/reactos/base/system/services/database.c [iso-8859-1] Sat Jul 16 17:41:44 2016 @@ -202,9 +202,9 @@ PWSTR ptr; DWORD dwError = ERROR_SUCCESS; - DPRINT1("ScmLogonService()\n"); - - DPRINT1("Service %S\n", pService->lpServiceName); + DPRINT("ScmLogonService()\n"); + + DPRINT("Service %S\n", pService->lpServiceName); if (ScmIsLocalSystemAccount(pImage->pszAccountName)) return ERROR_SUCCESS; @@ -228,10 +228,10 @@ // pDomainName = computer name } - DPRINT1("Domain: %S User: %S\n", pDomainName, pUserName); + DPRINT("Domain: %S User: %S\n", pDomainName, pUserName); /* FIXME */ -#if 1 +#if 0 if (!LogonUserW(pUserName, pDomainName, L"", // lpszPassword,
8 years, 5 months
1
0
0
0
[ekohl] 71954: [SERVICES] Check for NULL pointers before derreferecing them in ScmIsSameServiceAccount(). Patch by Victor Martinez Calvo. CORE-11599 #resolve #comment Thanks a lot!
by ekohl@svn.reactos.org
Author: ekohl Date: Sat Jul 16 17:39:37 2016 New Revision: 71954 URL:
http://svn.reactos.org/svn/reactos?rev=71954&view=rev
Log: [SERVICES] Check for NULL pointers before derreferecing them in ScmIsSameServiceAccount(). Patch by Victor Martinez Calvo. CORE-11599 #resolve #comment Thanks a lot! Modified: trunk/reactos/base/system/services/database.c Modified: trunk/reactos/base/system/services/database.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/system/services/datab…
============================================================================== --- trunk/reactos/base/system/services/database.c [iso-8859-1] (original) +++ trunk/reactos/base/system/services/database.c [iso-8859-1] Sat Jul 16 17:39:37 2016 @@ -162,10 +162,16 @@ IN PWSTR pszAccountName1, IN PWSTR pszAccountName2) { - if ((pszAccountName1 == NULL && pszAccountName2 == NULL) || - (pszAccountName1 == NULL && wcscmp(pszAccountName2, L"LocalSystem") == 0) || - (pszAccountName2 == NULL && wcscmp(pszAccountName1, L"LocalSystem") == 0) || - (wcscmp(pszAccountName1, pszAccountName2) == 0)) + if (pszAccountName1 == NULL && pszAccountName2 == NULL) + return TRUE; + + if (pszAccountName1 == NULL && pszAccountName2 && wcscmp(pszAccountName2, L"LocalSystem") == 0) + return TRUE; + + if (pszAccountName2 == NULL && pszAccountName1 && wcscmp(pszAccountName1, L"LocalSystem") == 0) + return TRUE; + + if (pszAccountName1 && pszAccountName2 && wcscmp(pszAccountName1, pszAccountName2) == 0) return TRUE; return FALSE; @@ -196,9 +202,9 @@ PWSTR ptr; DWORD dwError = ERROR_SUCCESS; - DPRINT("ScmLogonService()\n"); - - DPRINT("Service %S\n", pService->lpServiceName); + DPRINT1("ScmLogonService()\n"); + + DPRINT1("Service %S\n", pService->lpServiceName); if (ScmIsLocalSystemAccount(pImage->pszAccountName)) return ERROR_SUCCESS; @@ -222,10 +228,10 @@ // pDomainName = computer name } - DPRINT("Domain: %S User: %S\n", pDomainName, pUserName); + DPRINT1("Domain: %S User: %S\n", pDomainName, pUserName); /* FIXME */ -#if 0 +#if 1 if (!LogonUserW(pUserName, pDomainName, L"", // lpszPassword,
8 years, 5 months
1
0
0
0
[ekohl] 71953: [ADVAPI32] Remove unneeded NULL checks at CreateServiceA/W and ChangeServiceConfigW/A(). Patch by Victor Martinez Calvo. CORE-11610 #resolve #comment Thanks a lot!
by ekohl@svn.reactos.org
Author: ekohl Date: Sat Jul 16 16:18:17 2016 New Revision: 71953 URL:
http://svn.reactos.org/svn/reactos?rev=71953&view=rev
Log: [ADVAPI32] Remove unneeded NULL checks at CreateServiceA/W and ChangeServiceConfigW/A(). Patch by Victor Martinez Calvo. CORE-11610 #resolve #comment Thanks a lot! Modified: trunk/reactos/dll/win32/advapi32/service/scm.c Modified: trunk/reactos/dll/win32/advapi32/service/scm.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/advapi32/service…
============================================================================== --- trunk/reactos/dll/win32/advapi32/service/scm.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/advapi32/service/scm.c [iso-8859-1] Sat Jul 16 16:18:17 2016 @@ -326,7 +326,7 @@ /* FIXME: Encrypt the password */ lpEncryptedPassword = (LPBYTE)lpPasswordW; - dwPasswordLength = (DWORD)(lpPasswordW ? (wcslen(lpPasswordW) + 1) * sizeof(WCHAR) : 0); + dwPasswordLength = (wcslen(lpPasswordW) + 1) * sizeof(WCHAR); } RpcTryExcept @@ -407,9 +407,12 @@ dwDependenciesLength *= sizeof(WCHAR); } - /* FIXME: Encrypt the password */ - lpEncryptedPassword = (LPBYTE)lpPassword; - dwPasswordLength = (lpPassword ? (wcslen(lpPassword) + 1) * sizeof(WCHAR) : 0); + if (lpPassword != NULL) + { + /* FIXME: Encrypt the password */ + lpEncryptedPassword = (LPBYTE)lpPassword; + dwPasswordLength = (wcslen(lpPassword) + 1) * sizeof(WCHAR); + } RpcTryExcept { @@ -619,7 +622,7 @@ /* FIXME: Encrypt the password */ lpEncryptedPassword = (LPBYTE)lpPasswordW; - dwPasswordLength = (DWORD)(lpPasswordW ? (wcslen(lpPasswordW) + 1) * sizeof(WCHAR) : 0); + dwPasswordLength = (wcslen(lpPasswordW) + 1) * sizeof(WCHAR); } RpcTryExcept @@ -714,9 +717,12 @@ dwDependenciesLength *= sizeof(WCHAR); } - /* FIXME: Encrypt the password */ - lpEncryptedPassword = (LPBYTE)lpPassword; - dwPasswordLength = (DWORD)(lpPassword ? (wcslen(lpPassword) + 1) * sizeof(WCHAR) : 0); + if (lpPassword != NULL) + { + /* FIXME: Encrypt the password */ + lpEncryptedPassword = (LPBYTE)lpPassword; + dwPasswordLength = (wcslen(lpPassword) + 1) * sizeof(WCHAR); + } RpcTryExcept {
8 years, 5 months
1
0
0
0
[ekohl] 71952: [LSASRV] Fix cleanup in LsarRetrievePrivateData(). Modified patch by Victor Martinez Calvo. CORE-11611 #resolve #comment Thanks a lot!
by ekohl@svn.reactos.org
Author: ekohl Date: Sat Jul 16 14:57:33 2016 New Revision: 71952 URL:
http://svn.reactos.org/svn/reactos?rev=71952&view=rev
Log: [LSASRV] Fix cleanup in LsarRetrievePrivateData(). Modified patch by Victor Martinez Calvo. CORE-11611 #resolve #comment Thanks a lot! Modified: trunk/reactos/dll/win32/lsasrv/lsarpc.c Modified: trunk/reactos/dll/win32/lsasrv/lsarpc.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/lsasrv/lsarpc.c?…
============================================================================== --- trunk/reactos/dll/win32/lsasrv/lsarpc.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/lsasrv/lsarpc.c [iso-8859-1] Sat Jul 16 14:57:33 2016 @@ -2625,10 +2625,10 @@ if (EncCurrentValue != NULL) midl_user_free(EncCurrentValue); - - if (SecretObject != NULL) - LsapCloseDbObject(SecretObject); - } + } + + if (SecretObject != NULL) + LsapCloseDbObject(SecretObject); return Status; }
8 years, 5 months
1
0
0
0
[tfaber] 71951: [WS2_32] - Fix a few ws2_32:getaddrinfo test failures. Based on a patch by Peter Hater. CORE-11368
by tfaber@svn.reactos.org
Author: tfaber Date: Sat Jul 16 07:49:30 2016 New Revision: 71951 URL:
http://svn.reactos.org/svn/reactos?rev=71951&view=rev
Log: [WS2_32] - Fix a few ws2_32:getaddrinfo test failures. Based on a patch by Peter Hater. CORE-11368 Modified: trunk/reactos/dll/win32/ws2_32/misc/ns.c Modified: trunk/reactos/dll/win32/ws2_32/misc/ns.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/ws2_32/misc/ns.c…
============================================================================== --- trunk/reactos/dll/win32/ws2_32/misc/ns.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/ws2_32/misc/ns.c [iso-8859-1] Sat Jul 16 07:49:30 2016 @@ -1605,20 +1605,17 @@ struct sockaddr_in *sin; INT error; - if (res == NULL) - { - error = WSAEINVAL; + if (!WSAINITIALIZED) + { + error = WSANOTINITIALISED; goto End; } + + *res = NULL; + if (nodename == NULL && servname == NULL) { error = WSAHOST_NOT_FOUND; - goto End; - } - - if (!WSAINITIALIZED) - { - error = WSANOTINITIALISED; goto End; }
8 years, 5 months
1
0
0
0
[tfaber] 71950: [KERNEL32] - Fix GetComputerNameEx behavior with regard to NULL/non-NULL buffers and size calculation CORE-11368
by tfaber@svn.reactos.org
Author: tfaber Date: Sat Jul 16 07:08:21 2016 New Revision: 71950 URL:
http://svn.reactos.org/svn/reactos?rev=71950&view=rev
Log: [KERNEL32] - Fix GetComputerNameEx behavior with regard to NULL/non-NULL buffers and size calculation CORE-11368 Added: trunk/rostests/apitests/kernel32/GetComputerNameEx.c (with props) Modified: trunk/reactos/dll/win32/kernel32/client/compname.c trunk/rostests/apitests/kernel32/CMakeLists.txt trunk/rostests/apitests/kernel32/testlist.c Modified: trunk/reactos/dll/win32/kernel32/client/compname.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/kernel32/client/…
============================================================================== --- trunk/reactos/dll/win32/kernel32/client/compname.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/kernel32/client/compname.c [iso-8859-1] Sat Jul 16 07:08:21 2016 @@ -88,7 +88,7 @@ if (!NT_SUCCESS(Status)) { - *nSize = ReturnSize; + *nSize = (ReturnSize - FIELD_OFFSET(KEY_VALUE_PARTIAL_INFORMATION, Data)) / sizeof(WCHAR); goto failed; } @@ -100,7 +100,7 @@ if (!lpBuffer || *nSize < (KeyInfo->DataLength / sizeof(WCHAR))) { - *nSize = ReturnSize; + *nSize = (ReturnSize - FIELD_OFFSET(KEY_VALUE_PARTIAL_INFORMATION, Data)) / sizeof(WCHAR); Status = STATUS_BUFFER_OVERFLOW; goto failed; } @@ -134,6 +134,13 @@ NTSTATUS Status; BOOL ret = TRUE; DWORD HostSize; + + if ((nSize == NULL) || + (lpBuffer == NULL && *nSize > 0)) + { + SetLastError(ERROR_INVALID_PARAMETER); + return FALSE; + } switch (NameType) { @@ -263,19 +270,23 @@ UNICODE_STRING UnicodeString; ANSI_STRING AnsiString; BOOL Result; - PWCHAR TempBuffer; - - if (!lpBuffer) + PWCHAR TempBuffer = NULL; + + if ((nSize == NULL) || + (lpBuffer == NULL && *nSize > 0)) { SetLastError(ERROR_INVALID_PARAMETER); return FALSE; } - TempBuffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, *nSize * sizeof(WCHAR)); - if (!TempBuffer) - { - SetLastError(ERROR_NOT_ENOUGH_MEMORY); - return FALSE; + if (*nSize > 0) + { + TempBuffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, *nSize * sizeof(WCHAR)); + if (!TempBuffer) + { + SetLastError(ERROR_NOT_ENOUGH_MEMORY); + return FALSE; + } } AnsiString.MaximumLength = (USHORT)*nSize; @@ -287,7 +298,7 @@ if (Result) { UnicodeString.MaximumLength = (USHORT)*nSize * sizeof(WCHAR) + sizeof(WCHAR); - UnicodeString.Length = (USHORT)*nSize * sizeof(WCHAR) + sizeof(WCHAR); + UnicodeString.Length = (USHORT)*nSize * sizeof(WCHAR); UnicodeString.Buffer = TempBuffer; RtlUnicodeStringToAnsiString(&AnsiString, Modified: trunk/rostests/apitests/kernel32/CMakeLists.txt URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/kernel32/CMakeLi…
============================================================================== --- trunk/rostests/apitests/kernel32/CMakeLists.txt [iso-8859-1] (original) +++ trunk/rostests/apitests/kernel32/CMakeLists.txt [iso-8859-1] Sat Jul 16 07:08:21 2016 @@ -2,6 +2,7 @@ list(APPEND SOURCE dosdev.c FindFiles.c + GetComputerNameEx.c GetCurrentDirectory.c GetDriveType.c GetModuleFileName.c Added: trunk/rostests/apitests/kernel32/GetComputerNameEx.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/kernel32/GetComp…
============================================================================== --- trunk/rostests/apitests/kernel32/GetComputerNameEx.c (added) +++ trunk/rostests/apitests/kernel32/GetComputerNameEx.c [iso-8859-1] Sat Jul 16 07:08:21 2016 @@ -0,0 +1,192 @@ +/* + * PROJECT: ReactOS API tests + * LICENSE: LGPLv2.1+ - See COPYING.LIB in the top level directory + * PURPOSE: Test for GetComputerNameEx + * PROGRAMMER: Thomas Faber <thomas.faber(a)reactos.org> + */ + +#include <apitest.h> + +#define WIN32_NO_STATUS +#include <stdio.h> +#include <ndk/rtltypes.h> + +static +VOID +TestGetComputerNameEx( + _In_ COMPUTER_NAME_FORMAT NameType) +{ + WCHAR Reference[128]; + DWORD ReferenceLen; + WCHAR BufferW[128]; + CHAR BufferA[128]; + BOOL Ret; + DWORD Size; + DWORD Error; + ULONG i; + + Size = RTL_NUMBER_OF(Reference); + Ret = GetComputerNameExW(NameType, Reference, &Size); + ok(Ret == TRUE, "[%d] GetComputerNameExW returned %d\n", NameType, Ret); + if (!Ret) + { + skip("[%d] Failed to get reference string\n", NameType); + return; + } + trace("[%d] Reference is %ls\n", NameType, Reference); + ReferenceLen = wcslen(Reference); + ok(ReferenceLen < RTL_NUMBER_OF(Reference), + "[%d] Unexpected ReferenceLen %lu\n", NameType, ReferenceLen); + if (NameType != ComputerNameDnsDomain && NameType != ComputerNamePhysicalDnsDomain) + { + ok(ReferenceLen != 0, "[%d] Unexpected ReferenceLen %lu\n", NameType, ReferenceLen); + } + ok(Size == ReferenceLen, "[%d] Size is %lu, expected %lu\n", NameType, Size, ReferenceLen); + + /* NULL buffer, NULL size */ + StartSeh() + Ret = GetComputerNameExW(NameType, NULL, NULL); + Error = GetLastError(); + ok(Ret == FALSE, "[%d] GetComputerNameExW returned %d\n", NameType, Ret); + ok(Error == ERROR_INVALID_PARAMETER, "[%d] GetComputerNameExW returned error %lu\n", NameType, Error); + EndSeh(STATUS_SUCCESS); + StartSeh() + Ret = GetComputerNameExA(NameType, NULL, NULL); + Error = GetLastError(); + ok(Ret == FALSE, "[%d] GetComputerNameExW returned %d\n", NameType, Ret); + ok(Error == ERROR_INVALID_PARAMETER, "[%d] GetComputerNameExW returned error %lu\n", NameType, Error); + EndSeh(STATUS_SUCCESS); + + /* NULL buffer, nonzero size */ + Size = 0x55555555; + Ret = GetComputerNameExW(NameType, NULL, &Size); + Error = GetLastError(); + ok(Ret == FALSE, "[%d] GetComputerNameExW returned %d\n", NameType, Ret); + ok(Error == ERROR_INVALID_PARAMETER, "[%d] GetComputerNameExW returned error %lu\n", NameType, Error); + ok(Size == 0x55555555, "[%d] Got Size %lu\n", NameType, Size); + + Size = 0x55555555; + Ret = GetComputerNameExA(NameType, NULL, &Size); + Error = GetLastError(); + ok(Ret == FALSE, "[%d] GetComputerNameExA returned %d\n", NameType, Ret); + ok(Error == ERROR_INVALID_PARAMETER, "[%d] GetComputerNameExA returned error %lu\n", NameType, Error); + ok(Size == 0x55555555, "[%d] Got Size %lu\n", NameType, Size); + + /* non-NULL buffer, NULL size */ + RtlFillMemory(BufferW, sizeof(BufferW), 0x55); + Ret = GetComputerNameExW(NameType, BufferW, NULL); + Error = GetLastError(); + ok(Ret == FALSE, "[%d] GetComputerNameExW returned %d\n", NameType, Ret); + ok(Error == ERROR_INVALID_PARAMETER, "[%d] GetComputerNameExW returned error %lu\n", NameType, Error); + ok(BufferW[0] == 0x5555, "[%d] BufferW[0] = 0x%x\n", NameType, BufferW[0]); + + RtlFillMemory(BufferA, sizeof(BufferA), 0x55); + Ret = GetComputerNameExA(NameType, BufferA, NULL); + Error = GetLastError(); + ok(Ret == FALSE, "[%d] GetComputerNameExA returned %d\n", NameType, Ret); + ok(Error == ERROR_INVALID_PARAMETER, "[%d] GetComputerNameExA returned error %lu\n", NameType, Error); + ok(BufferA[0] == 0x55, "[%d] BufferA[0] = 0x%x\n", NameType, BufferA[0]); + + /* NULL buffer, zero size */ + Size = 0; + Ret = GetComputerNameExW(NameType, NULL, &Size); + Error = GetLastError(); + ok(Ret == FALSE, "[%d] GetComputerNameExW returned %d\n", NameType, Ret); + ok(Error == ERROR_MORE_DATA, "[%d] GetComputerNameExW returned error %lu\n", NameType, Error); + ok(Size == ReferenceLen + 1, "[%d] Got Size %lu, expected %lu\n", NameType, Size, ReferenceLen + 1); + + Size = 0; + Ret = GetComputerNameExA(NameType, NULL, &Size); + Error = GetLastError(); + ok(Ret == FALSE, "[%d] GetComputerNameExA returned %d\n", NameType, Ret); + ok(Error == ERROR_MORE_DATA, "[%d] GetComputerNameExA returned error %lu\n", NameType, Error); + ok(Size == ReferenceLen + 1, "[%d] Got Size %lu, expected %lu\n", NameType, Size, ReferenceLen + 1); + + /* non-NULL buffer, zero size */ + RtlFillMemory(BufferW, sizeof(BufferW), 0x55); + Size = 0; + Ret = GetComputerNameExW(NameType, BufferW, &Size); + Error = GetLastError(); + ok(Ret == FALSE, "[%d] GetComputerNameExW returned %d\n", NameType, Ret); + ok(Error == ERROR_MORE_DATA, "[%d] GetComputerNameExW returned error %lu\n", NameType, Error); + ok(Size == ReferenceLen + 1, "[%d] Got Size %lu, expected %lu\n", NameType, Size, ReferenceLen + 1); + ok(BufferW[0] == 0x5555, "[%d] BufferW[0] = 0x%x\n", NameType, BufferW[0]); + + RtlFillMemory(BufferA, sizeof(BufferA), 0x55); + Size = 0; + Ret = GetComputerNameExA(NameType, BufferA, &Size); + Error = GetLastError(); + ok(Ret == FALSE, "[%d] GetComputerNameExA returned %d\n", NameType, Ret); + ok(Error == ERROR_MORE_DATA, "[%d] GetComputerNameExA returned error %lu\n", NameType, Error); + ok(Size == ReferenceLen + 1, "[%d] Got Size %lu, expected %lu\n", NameType, Size, ReferenceLen + 1); + ok(BufferA[0] == 0x55, "[%d] BufferA[0] = 0x%x\n", NameType, BufferA[0]); + + /* non-NULL buffer, too small size */ + RtlFillMemory(BufferW, sizeof(BufferW), 0x55); + Size = ReferenceLen; + Ret = GetComputerNameExW(NameType, BufferW, &Size); + Error = GetLastError(); + ok(Ret == FALSE, "[%d] GetComputerNameExW returned %d\n", NameType, Ret); + ok(Error == ERROR_MORE_DATA, "[%d] GetComputerNameExW returned error %lu\n", NameType, Error); + ok(Size == ReferenceLen + 1, "[%d] Got Size %lu, expected %lu\n", NameType, Size, ReferenceLen + 1); + if (NameType != ComputerNameNetBIOS && NameType != ComputerNamePhysicalNetBIOS) + { + if (ReferenceLen == 0) + { + ok(BufferW[0] == 0x5555, "[%d] BufferW[0] = 0x%x\n", + NameType, BufferW[0]); + } + else + { + ok(BufferW[0] == 0, "[%d] BufferW[0] = 0x%x\n", + NameType, BufferW[0]); + } + } + ok(BufferW[1] == 0x5555, "[%d] BufferW[1] = 0x%x\n", NameType, BufferW[1]); + + RtlFillMemory(BufferA, sizeof(BufferA), 0x55); + Size = ReferenceLen; + Ret = GetComputerNameExA(NameType, BufferA, &Size); + Error = GetLastError(); + ok(Ret == FALSE, "[%d] GetComputerNameExA returned %d\n", NameType, Ret); + ok(Error == ERROR_MORE_DATA, "[%d] GetComputerNameExA returned error %lu\n", NameType, Error); + ok(Size == ReferenceLen + 1, "[%d] Got Size %lu, expected %lu\n", NameType, Size, ReferenceLen + 1); + ok(BufferA[0] == 0x55, "[%d] BufferA[0] = 0x%x\n", NameType, BufferA[0]); + + /* non-NULL buffer, exact size */ + RtlFillMemory(BufferW, sizeof(BufferW), 0x55); + Size = ReferenceLen + 1; + Ret = GetComputerNameExW(NameType, BufferW, &Size); + ok(Ret == TRUE, "[%d] GetComputerNameExW returned %d\n", NameType, Ret); + ok(Size == ReferenceLen, "[%d] Got Size %lu, expected %lu\n", NameType, Size, ReferenceLen + 1); + ok(BufferW[ReferenceLen] == 0, "[%d] BufferW[ReferenceLen] = 0x%x\n", NameType, BufferW[ReferenceLen]); + ok(BufferW[ReferenceLen + 1] == 0x5555, "[%d] BufferW[ReferenceLen + 1] = 0x%x\n", NameType, BufferW[ReferenceLen + 1]); + ok(!wcscmp(BufferW, Reference), "[%d] '%ls' != '%ls'\n", NameType, BufferW, Reference); + + RtlFillMemory(BufferA, sizeof(BufferA), 0x55); + Size = ReferenceLen + 1; + Ret = GetComputerNameExA(NameType, BufferA, &Size); + ok(Ret == TRUE, "[%d] GetComputerNameExA returned %d\n", NameType, Ret); + ok(Size == ReferenceLen, "[%d] Got Size %lu, expected %lu\n", NameType, Size, ReferenceLen + 1); + ok(BufferA[ReferenceLen] == 0, "[%d] BufferA[ReferenceLen] = 0x%x\n", NameType, BufferA[ReferenceLen]); + ok(BufferA[ReferenceLen + 1] == 0x55, "[%d] BufferA[ReferenceLen + 1] = 0x%x\n", NameType, BufferA[ReferenceLen + 1]); + for (i = 0; i < ReferenceLen; i++) + { + if (BufferA[i] != Reference[i]) + { + ok(0, "[%d] BufferA[%lu] = 0x%x, expected 0x%x\n", NameType, i, BufferA[i], Reference[i]); + } + } +} + +START_TEST(GetComputerNameEx) +{ + TestGetComputerNameEx(ComputerNameNetBIOS); + TestGetComputerNameEx(ComputerNameDnsHostname); + TestGetComputerNameEx(ComputerNameDnsDomain); + //TestGetComputerNameEx(ComputerNameDnsFullyQualified); + TestGetComputerNameEx(ComputerNamePhysicalNetBIOS); + TestGetComputerNameEx(ComputerNamePhysicalDnsHostname); + TestGetComputerNameEx(ComputerNamePhysicalDnsDomain); + //TestGetComputerNameEx(ComputerNamePhysicalDnsFullyQualified); +} Propchange: trunk/rostests/apitests/kernel32/GetComputerNameEx.c ------------------------------------------------------------------------------ svn:eol-style = native Modified: trunk/rostests/apitests/kernel32/testlist.c URL:
http://svn.reactos.org/svn/reactos/trunk/rostests/apitests/kernel32/testlis…
============================================================================== --- trunk/rostests/apitests/kernel32/testlist.c [iso-8859-1] (original) +++ trunk/rostests/apitests/kernel32/testlist.c [iso-8859-1] Sat Jul 16 07:08:21 2016 @@ -5,6 +5,7 @@ extern void func_dosdev(void); extern void func_FindFiles(void); +extern void func_GetComputerNameEx(void); extern void func_GetCurrentDirectory(void); extern void func_GetDriveType(void); extern void func_GetModuleFileName(void); @@ -22,6 +23,7 @@ { { "dosdev", func_dosdev }, { "FindFiles", func_FindFiles }, + { "GetComputerNameEx", func_GetComputerNameEx }, { "GetCurrentDirectory", func_GetCurrentDirectory }, { "GetDriveType", func_GetDriveType }, { "GetModuleFileName", func_GetModuleFileName },
8 years, 5 months
1
0
0
0
[mjansen] 71949: [EXPLORER] HACK: ignore unimplemented SetBandSiteInfo. Patch by Wim Hueskes. CORE-9809 #resolve #comment Thanks!
by mjansen@svn.reactos.org
Author: mjansen Date: Fri Jul 15 23:33:53 2016 New Revision: 71949 URL:
http://svn.reactos.org/svn/reactos?rev=71949&view=rev
Log: [EXPLORER] HACK: ignore unimplemented SetBandSiteInfo. Patch by Wim Hueskes. CORE-9809 #resolve #comment Thanks! Modified: trunk/reactos/base/shell/explorer/tbsite.cpp Modified: trunk/reactos/base/shell/explorer/tbsite.cpp URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/explorer/tbsite…
============================================================================== --- trunk/reactos/base/shell/explorer/tbsite.cpp [iso-8859-1] (original) +++ trunk/reactos/base/shell/explorer/tbsite.cpp [iso-8859-1] Fri Jul 15 23:33:53 2016 @@ -334,6 +334,13 @@ bsi.dwStyle = (Locked ? BSIS_LOCKED | BSIS_NOGRIPPER : BSIS_AUTOGRIPPER); hRet = m_BandSite->SetBandSiteInfo(&bsi); + + /* HACK for CORE-9809 ! */ + if (hRet == E_NOTIMPL) + hRet = S_OK; + else + ERR("HACK for CORE-9809 no longer needed!\n"); + if (SUCCEEDED(hRet)) { hRet = Update();
8 years, 5 months
1
0
0
0
[hbelusca] 71948: [PSDK]: Add two missing flags concerning custom-drawn controls.
by hbelusca@svn.reactos.org
Author: hbelusca Date: Fri Jul 15 21:12:52 2016 New Revision: 71948 URL:
http://svn.reactos.org/svn/reactos?rev=71948&view=rev
Log: [PSDK]: Add two missing flags concerning custom-drawn controls. Modified: trunk/reactos/sdk/include/psdk/commctrl.h Modified: trunk/reactos/sdk/include/psdk/commctrl.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/sdk/include/psdk/commctrl.…
============================================================================== --- trunk/reactos/sdk/include/psdk/commctrl.h [iso-8859-1] (original) +++ trunk/reactos/sdk/include/psdk/commctrl.h [iso-8859-1] Fri Jul 15 21:12:52 2016 @@ -253,6 +253,8 @@ #define CDRF_DODEFAULT 0x0 #define CDRF_NEWFONT 0x2 #define CDRF_SKIPDEFAULT 0x4 +#define CDRF_DOERASE 0x8 +#define CDRF_SKIPPOSTPAINT 0x100 #define CDRF_NOTIFYPOSTPAINT 0x10 #define CDRF_NOTIFYITEMDRAW 0x20
8 years, 5 months
1
0
0
0
[akhaldi] 71947: [KERNEL32] Check the return buffer for NULL before initializing the unicode string buffer with it. By Peter Hater. CORE-11368
by akhaldi@svn.reactos.org
Author: akhaldi Date: Fri Jul 15 20:18:20 2016 New Revision: 71947 URL:
http://svn.reactos.org/svn/reactos?rev=71947&view=rev
Log: [KERNEL32] Check the return buffer for NULL before initializing the unicode string buffer with it. By Peter Hater. CORE-11368 Modified: trunk/reactos/dll/win32/kernel32/client/compname.c Modified: trunk/reactos/dll/win32/kernel32/client/compname.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/kernel32/client/…
============================================================================== --- trunk/reactos/dll/win32/kernel32/client/compname.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/kernel32/client/compname.c [iso-8859-1] Fri Jul 15 20:18:20 2016 @@ -263,8 +263,15 @@ UNICODE_STRING UnicodeString; ANSI_STRING AnsiString; BOOL Result; - PWCHAR TempBuffer = RtlAllocateHeap( RtlGetProcessHeap(), 0, *nSize * sizeof(WCHAR) ); - + PWCHAR TempBuffer; + + if (!lpBuffer) + { + SetLastError(ERROR_INVALID_PARAMETER); + return FALSE; + } + + TempBuffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, *nSize * sizeof(WCHAR)); if (!TempBuffer) { SetLastError(ERROR_NOT_ENOUGH_MEMORY);
8 years, 5 months
1
0
0
0
← Newer
1
...
9
10
11
12
13
14
15
...
36
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
Results per page:
10
25
50
100
200