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
2025
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
List overview
Download
Ros-diffs
December 2019
----- 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
ros-diffs@reactos.org
18 participants
225 discussions
Start a n
N
ew thread
[reactos] 01/01: [DNSAPI] Set proper record flags for query results and converted records
by Eric Kohl
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=b4777797aaa287f71fe87…
commit b4777797aaa287f71fe877b9d2a229b98c7deaf4 Author: Eric Kohl <eric.kohl(a)reactos.org> AuthorDate: Sun Dec 22 14:40:18 2019 +0100 Commit: Eric Kohl <eric.kohl(a)reactos.org> CommitDate: Sun Dec 22 14:40:18 2019 +0100 [DNSAPI] Set proper record flags for query results and converted records --- dll/win32/dnsapi/query.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/dll/win32/dnsapi/query.c b/dll/win32/dnsapi/query.c index f16d8ec883f..0603b322390 100644 --- a/dll/win32/dnsapi/query.c +++ b/dll/win32/dnsapi/query.c @@ -223,9 +223,15 @@ DnsQuery_CodePage(UINT CodePage, } if (CodePage == CP_ACP) + { ConvertedRecord->pName = DnsWToC((PWCHAR)QueryResultWide->pName); + ConvertedRecord->Flags.S.CharSet = DnsCharSetAnsi; + } else + { ConvertedRecord->pName = DnsWToUTF8((PWCHAR)QueryResultWide->pName); + ConvertedRecord->Flags.S.CharSet = DnsCharSetUtf8; + } ConvertedRecord->wType = QueryResultWide->wType; @@ -625,6 +631,8 @@ Query_Main(LPCWSTR Name, (*QueryResultSet)->pNext = NULL; (*QueryResultSet)->wType = Type; (*QueryResultSet)->wDataLength = sizeof(DNS_A_DATA); + (*QueryResultSet)->Flags.S.Section = DnsSectionAnswer; + (*QueryResultSet)->Flags.S.CharSet = DnsCharSetUnicode; (*QueryResultSet)->Data.A.IpAddress = Address; (*QueryResultSet)->pName = (LPSTR)xstrsave(Name); @@ -696,6 +704,8 @@ Query_Main(LPCWSTR Name, (*QueryResultSet)->pNext = NULL; (*QueryResultSet)->wType = Type; (*QueryResultSet)->wDataLength = sizeof(DNS_A_DATA); + (*QueryResultSet)->Flags.S.Section = DnsSectionAnswer; + (*QueryResultSet)->Flags.S.CharSet = DnsCharSetUnicode; (*QueryResultSet)->Data.A.IpAddress = Address; (*QueryResultSet)->pName = (LPSTR)DnsCToW(HostWithDomainName); @@ -787,6 +797,8 @@ Query_Main(LPCWSTR Name, (*QueryResultSet)->pNext = NULL; (*QueryResultSet)->wType = Type; (*QueryResultSet)->wDataLength = sizeof(DNS_A_DATA); + (*QueryResultSet)->Flags.S.Section = DnsSectionAnswer; + (*QueryResultSet)->Flags.S.CharSet = DnsCharSetUnicode; (*QueryResultSet)->Data.A.IpAddress = answer->rrs.addr->addr.inet.sin_addr.s_addr; adns_finish(astate);
5 years, 3 months
1
0
0
0
[reactos] 01/01: [IDL] Add missing acf files
by Eric Kohl
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=75f66049cfb8a0b03a11e…
commit 75f66049cfb8a0b03a11eab1576a70d106777d78 Author: Eric Kohl <eric.kohl(a)reactos.org> AuthorDate: Sun Dec 22 12:43:23 2019 +0100 Commit: Eric Kohl <eric.kohl(a)reactos.org> CommitDate: Sun Dec 22 12:43:23 2019 +0100 [IDL] Add missing acf files --- sdk/include/reactos/idl/dnsrslvr.acf | 6 ++++++ sdk/include/reactos/idl/netdfs.acf | 6 ++++++ sdk/include/reactos/idl/wlansvc.acf | 6 ++++++ 3 files changed, 18 insertions(+) diff --git a/sdk/include/reactos/idl/dnsrslvr.acf b/sdk/include/reactos/idl/dnsrslvr.acf new file mode 100644 index 00000000000..369e389204d --- /dev/null +++ b/sdk/include/reactos/idl/dnsrslvr.acf @@ -0,0 +1,6 @@ +[ + explicit_handle +] +interface DnsResolver +{ +} \ No newline at end of file diff --git a/sdk/include/reactos/idl/netdfs.acf b/sdk/include/reactos/idl/netdfs.acf new file mode 100644 index 00000000000..fc3b35f2821 --- /dev/null +++ b/sdk/include/reactos/idl/netdfs.acf @@ -0,0 +1,6 @@ +[ + implicit_handle(handle_t hBinding) +] +interface netdfs +{ +} \ No newline at end of file diff --git a/sdk/include/reactos/idl/wlansvc.acf b/sdk/include/reactos/idl/wlansvc.acf new file mode 100644 index 00000000000..bc46b7d5f17 --- /dev/null +++ b/sdk/include/reactos/idl/wlansvc.acf @@ -0,0 +1,6 @@ +[ + explicit_handle +] +interface wlansvc_interface +{ +} \ No newline at end of file
5 years, 3 months
1
0
0
0
[reactos] 01/01: [DNSAPI][DNSRSLVR] Implement DnsGetCacheDataTable()
by Eric Kohl
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=6c7878f35e086360ab9bc…
commit 6c7878f35e086360ab9bcbd8f1dfd4218f35d74f Author: Eric Kohl <eric.kohl(a)reactos.org> AuthorDate: Sun Dec 22 11:21:04 2019 +0100 Commit: Eric Kohl <eric.kohl(a)reactos.org> CommitDate: Sun Dec 22 11:21:04 2019 +0100 [DNSAPI][DNSRSLVR] Implement DnsGetCacheDataTable() --- base/services/dnsrslvr/cache.c | 57 ++++++++++++++++++++++++++++++++++++ base/services/dnsrslvr/precomp.h | 3 ++ base/services/dnsrslvr/rpcserver.c | 16 ++++++++++ dll/win32/dnsapi/query.c | 35 ++++++++++++++++++++++ dll/win32/dnsapi/stubs.c | 9 ------ sdk/include/reactos/idl/dnsrslvr.idl | 14 +++++---- sdk/include/reactos/windns_undoc.h | 4 +++ 7 files changed, 124 insertions(+), 14 deletions(-) diff --git a/base/services/dnsrslvr/cache.c b/base/services/dnsrslvr/cache.c index 748a1599383..af4cc2a8597 100644 --- a/base/services/dnsrslvr/cache.c +++ b/base/services/dnsrslvr/cache.c @@ -203,3 +203,60 @@ DnsIntCacheAddEntry(PDNS_RECORDW Record) /* Release the cache */ DnsCacheUnlock(); } + +DNS_STATUS +DnsIntCacheGetEntries( + _Out_ DNS_CACHE_ENTRY **ppCacheEntries) +{ + PRESOLVER_CACHE_ENTRY CacheEntry; + PLIST_ENTRY NextEntry; + PDNS_CACHE_ENTRY pLastEntry = NULL, pNewEntry; + + /* Lock the cache */ + DnsCacheLock(); + + *ppCacheEntries = NULL; + + NextEntry = DnsCache.RecordList.Flink; + while (NextEntry != &DnsCache.RecordList) + { + /* Get the Current Entry */ + CacheEntry = CONTAINING_RECORD(NextEntry, RESOLVER_CACHE_ENTRY, CacheLink); + + DPRINT("1 %S %lu\n", CacheEntry->Record->pName, CacheEntry->Record->wType); + if (CacheEntry->Record->pNext) + { + DPRINT("2 %S %lu\n", CacheEntry->Record->pNext->pName, CacheEntry->Record->pNext->wType); + } + + pNewEntry = midl_user_allocate(sizeof(DNS_CACHE_ENTRY)); + if (pNewEntry == NULL) + { + return ERROR_OUTOFMEMORY; + } + + pNewEntry->pszName = midl_user_allocate((wcslen(CacheEntry->Record->pName) + 1) * sizeof(WCHAR)); + if (pNewEntry->pszName == NULL) + { + return ERROR_OUTOFMEMORY; + } + + wcscpy(pNewEntry->pszName, CacheEntry->Record->pName); + pNewEntry->wType1 = CacheEntry->Record->wType; + pNewEntry->wType2 = 0; + pNewEntry->wFlags = 0; + + if (pLastEntry == NULL) + *ppCacheEntries = pNewEntry; + else + pLastEntry->pNext = pNewEntry; + pLastEntry = pNewEntry; + + NextEntry = NextEntry->Flink; + } + + /* Release the cache */ + DnsCacheUnlock(); + + return ERROR_SUCCESS; +} diff --git a/base/services/dnsrslvr/precomp.h b/base/services/dnsrslvr/precomp.h index c0bbeecd30e..81189cda9e6 100644 --- a/base/services/dnsrslvr/precomp.h +++ b/base/services/dnsrslvr/precomp.h @@ -54,6 +54,9 @@ DnsIntCacheGetEntryByName( VOID DnsIntCacheAddEntry(PDNS_RECORDW Record); BOOL DnsIntCacheRemoveEntryByName(LPCWSTR Name); +DNS_STATUS +DnsIntCacheGetEntries( + _Out_ DNS_CACHE_ENTRY **ppCacheEntries); /* hostsfile.c */ diff --git a/base/services/dnsrslvr/rpcserver.c b/base/services/dnsrslvr/rpcserver.c index cb4b9476b04..f79850ddb06 100644 --- a/base/services/dnsrslvr/rpcserver.c +++ b/base/services/dnsrslvr/rpcserver.c @@ -41,6 +41,21 @@ RpcThreadRoutine(LPVOID lpParameter) return 0; } + +/* Function: 0x00 */ +DWORD +__stdcall +CRrReadCache( + _In_ DNSRSLVR_HANDLE pwszServerName, + _Out_ DNS_CACHE_ENTRY **ppCacheEntries) +{ + DPRINT("CRrReadCache(%S %p)\n", + pwszServerName, ppCacheEntries); + + return DnsIntCacheGetEntries(ppCacheEntries); +} + + /* Function: 0x04 */ DWORD __stdcall @@ -54,6 +69,7 @@ R_ResolverFlushCache( return ERROR_SUCCESS; } + /* Function: 0x07 */ DWORD __stdcall diff --git a/dll/win32/dnsapi/query.c b/dll/win32/dnsapi/query.c index 3ffaa41dffe..f16d8ec883f 100644 --- a/dll/win32/dnsapi/query.c +++ b/dll/win32/dnsapi/query.c @@ -896,6 +896,41 @@ DnsFlushResolverCache(VOID) return (Status == ERROR_SUCCESS); } +BOOL +WINAPI +DnsGetCacheDataTable( + _Out_ PDNS_CACHE_ENTRY *DnsCache) +{ + DNS_STATUS Status = ERROR_SUCCESS; + PDNS_CACHE_ENTRY CacheEntries = NULL; + + if (DnsCache == NULL) + return FALSE; + + RpcTryExcept + { + Status = CRrReadCache(NULL, + &CacheEntries); + DPRINT("CRrReadCache() returned %lu\n", Status); + } + RpcExcept(EXCEPTION_EXECUTE_HANDLER) + { + Status = RpcExceptionCode(); + DPRINT1("Exception returned %lu\n", Status); + } + RpcEndExcept; + + if (Status != ERROR_SUCCESS) + return FALSE; + + if (CacheEntries == NULL) + return FALSE; + + *DnsCache = CacheEntries; + + return TRUE; +} + DWORD WINAPI GetCurrentTimeInSeconds(VOID) diff --git a/dll/win32/dnsapi/stubs.c b/dll/win32/dnsapi/stubs.c index 0a4bf59db55..7d946ababfa 100644 --- a/dll/win32/dnsapi/stubs.c +++ b/dll/win32/dnsapi/stubs.c @@ -266,15 +266,6 @@ DnsGetBufferLengthForStringCopy() return ERROR_OUTOFMEMORY; } -BOOL -WINAPI -DnsGetCacheDataTable( - _Out_ PDNS_CACHE_ENTRY *DnsCache) -{ - UNIMPLEMENTED; - return TRUE; -} - DNS_STATUS WINAPI DnsGetDnsServerList() { diff --git a/sdk/include/reactos/idl/dnsrslvr.idl b/sdk/include/reactos/idl/dnsrslvr.idl index cae2e196e62..91cad5a52eb 100644 --- a/sdk/include/reactos/idl/dnsrslvr.idl +++ b/sdk/include/reactos/idl/dnsrslvr.idl @@ -28,7 +28,11 @@ typedef [handle, string] LPWSTR DNSRSLVR_HANDLE; interface DnsResolver { /* Function: 0x00 */ - /* CRrReadCache */ + DWORD + __stdcall + CRrReadCache( + [in, unique, string] DNSRSLVR_HANDLE pwszServerName, + [out] DNS_CACHE_ENTRY **ppCacheEntries); /* Function: 0x01 */ /* CRrReadCacheEntry */ @@ -56,10 +60,10 @@ interface DnsResolver __stdcall R_ResolverQuery( [in, unique, string] DNSRSLVR_HANDLE pwszServerName, - [in, unique, string] LPCWSTR pwsName, - [in] WORD wType, - [in] DWORD Flags, - [in, out] DWORD *dwRecords, + [in, unique, string] LPCWSTR pwsName, + [in] WORD wType, + [in] DWORD Flags, + [in, out] DWORD *dwRecords, [out] DNS_RECORDW **ppResultRecords); /* Function: 0x08 */ diff --git a/sdk/include/reactos/windns_undoc.h b/sdk/include/reactos/windns_undoc.h index 1b07f61f94a..ece0d38954f 100644 --- a/sdk/include/reactos/windns_undoc.h +++ b/sdk/include/reactos/windns_undoc.h @@ -8,7 +8,11 @@ extern "C" { typedef struct _DNS_CACHE_ENTRY { struct _DNS_CACHE_ENTRY *pNext; /* Pointer to next entry */ +#if defined(__midl) || defined(__WIDL__) + [string] PWSTR pszName; /* DNS Record Name */ +#else PWSTR pszName; /* DNS Record Name */ +#endif unsigned short wType1; /* DNS Record Type 1 */ unsigned short wType2; /* DNS Record Type 2 */ unsigned short wFlags; /* DNS Record Flags */
5 years, 3 months
1
0
0
0
[reactos] 01/01: [DNSRSLVR] Set proper flags for the hosts file entries
by Eric Kohl
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=6499cf9e1a7e5157c5f8d…
commit 6499cf9e1a7e5157c5f8dfbdef8c18e115982a96 Author: Eric Kohl <eric.kohl(a)reactos.org> AuthorDate: Sat Dec 21 22:12:21 2019 +0100 Commit: Eric Kohl <eric.kohl(a)reactos.org> CommitDate: Sat Dec 21 22:12:55 2019 +0100 [DNSRSLVR] Set proper flags for the hosts file entries --- base/services/dnsrslvr/hostsfile.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/base/services/dnsrslvr/hostsfile.c b/base/services/dnsrslvr/hostsfile.c index 98d39374d4e..1c80dc0cffb 100644 --- a/base/services/dnsrslvr/hostsfile.c +++ b/base/services/dnsrslvr/hostsfile.c @@ -105,6 +105,8 @@ AddIpv4HostEntries( ARecord.pName = pszHostName; ARecord.wType = DNS_TYPE_A; ARecord.wDataLength = sizeof(DNS_A_DATA); + ARecord.Flags.S.Section = DnsSectionAnswer; + ARecord.Flags.S.CharSet = DnsCharSetUnicode; ARecord.dwTtl = 86400; ARecord.Data.A.IpAddress = pAddress->S_un.S_addr; @@ -122,6 +124,8 @@ AddIpv4HostEntries( PtrRecord.pName = szReverseName; PtrRecord.wType = DNS_TYPE_PTR; PtrRecord.wDataLength = sizeof(DNS_PTR_DATA); + PtrRecord.Flags.S.Section = DnsSectionAnswer; + PtrRecord.Flags.S.CharSet = DnsCharSetUnicode; PtrRecord.dwTtl = 86400; PtrRecord.Data.PTR.pNameHost = pszHostName; @@ -147,6 +151,8 @@ AddIpv6HostEntries( AAAARecord.pName = pszHostName; AAAARecord.wType = DNS_TYPE_AAAA; AAAARecord.wDataLength = sizeof(DNS_AAAA_DATA); + AAAARecord.Flags.S.Section = DnsSectionAnswer; + AAAARecord.Flags.S.CharSet = DnsCharSetUnicode; AAAARecord.dwTtl = 86400; CopyMemory(&AAAARecord.Data.AAAA.Ip6Address, @@ -172,6 +178,8 @@ AddIpv6HostEntries( PtrRecord.pName = szReverseName; PtrRecord.wType = DNS_TYPE_PTR; PtrRecord.wDataLength = sizeof(DNS_PTR_DATA); + PtrRecord.Flags.S.Section = DnsSectionAnswer; + PtrRecord.Flags.S.CharSet = DnsCharSetUnicode; PtrRecord.dwTtl = 86400; PtrRecord.Data.PTR.pNameHost = pszHostName;
5 years, 3 months
1
0
0
0
[reactos] 01/01: [BOOTDATA][NTUSER] Fix GetSystemMetrics values (#2137)
by Katayama Hirofumi MZ
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=eba2d5d30aa5fe95b0232…
commit eba2d5d30aa5fe95b0232561931f54d8cbe9845d Author: Katayama Hirofumi MZ <katayama.hirofumi.mz(a)gmail.com> AuthorDate: Sat Dec 21 22:38:49 2019 +0900 Commit: GitHub <noreply(a)github.com> CommitDate: Sat Dec 21 22:38:49 2019 +0900 [BOOTDATA][NTUSER] Fix GetSystemMetrics values (#2137) Fix user32!GetSystemMetrics values. CORE-16547 SM_MENUDROPALIGNMENT and SM_CXSMSIZE --- boot/bootdata/hivedef.inf | 2 +- win32ss/user/ntuser/sysparams.c | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/boot/bootdata/hivedef.inf b/boot/bootdata/hivedef.inf index 49c7b8bd11e..dc322952a1f 100644 --- a/boot/bootdata/hivedef.inf +++ b/boot/bootdata/hivedef.inf @@ -87,7 +87,7 @@ HKCU,"Control Panel\Desktop\WindowMetrics","ScrollWidth",2,"16" HKCU,"Control Panel\Desktop\WindowMetrics","ScrollHeight",2,"16" HKCU,"Control Panel\Desktop\WindowMetrics","CaptionWidth",2,"18" HKCU,"Control Panel\Desktop\WindowMetrics","CaptionHeight",2,"18" -HKCU,"Control Panel\Desktop\WindowMetrics","SmCaptionWidth",2,"13" +HKCU,"Control Panel\Desktop\WindowMetrics","SmCaptionWidth",2,"12" HKCU,"Control Panel\Desktop\WindowMetrics","SmCaptionHeight",2,"15" HKCU,"Control Panel\Desktop\WindowMetrics","MenuWidth",2,"18" HKCU,"Control Panel\Desktop\WindowMetrics","MenuHeight",2,"18" diff --git a/win32ss/user/ntuser/sysparams.c b/win32ss/user/ntuser/sysparams.c index 4fa4c3d4918..4dd882987fd 100644 --- a/win32ss/user/ntuser/sysparams.c +++ b/win32ss/user/ntuser/sysparams.c @@ -257,7 +257,7 @@ SpiUpdatePerUserSystemParameters(VOID) gspv.ncm.iCaptionWidth = SpiLoadMetric(L"CaptionWidth", 19); gspv.ncm.iCaptionHeight = SpiLoadMetric(L"CaptionHeight", 19); gspv.ncm.iSmCaptionWidth = SpiLoadMetric(L"SmCaptionWidth", 12); - gspv.ncm.iSmCaptionHeight = SpiLoadMetric(L"SmCaptionHeight", 14); + gspv.ncm.iSmCaptionHeight = SpiLoadMetric(L"SmCaptionHeight", 15); gspv.ncm.iMenuWidth = SpiLoadMetric(L"MenuWidth", 18); gspv.ncm.iMenuHeight = SpiLoadMetric(L"MenuHeight", 18); #if (WINVER >= 0x0600) @@ -305,7 +305,7 @@ SpiUpdatePerUserSystemParameters(VOID) gspv.bBeep = TRUE; gspv.uiFocusBorderWidth = 1; gspv.uiFocusBorderHeight = 1; - gspv.bMenuDropAlign = 1; + gspv.bMenuDropAlign = 0; gspv.dwMenuShowDelay = 100; gspv.dwForegroundFlashCount = 3;
5 years, 3 months
1
0
0
0
[reactos] 08/08: [ATL_APITEST] Fix CComVariant test
by Mark Jansen
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=3d4a557db32a238ae6aa6…
commit 3d4a557db32a238ae6aa6209cbdb90fa816801ee Author: Mark Jansen <mark.jansen(a)reactos.org> AuthorDate: Sat Dec 14 17:16:00 2019 +0100 Commit: Timo Kreuzer <timo.kreuzer(a)reactos.org> CommitDate: Sat Dec 21 12:44:48 2019 +0100 [ATL_APITEST] Fix CComVariant test --- modules/rostests/apitests/atl/CComVariant.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/modules/rostests/apitests/atl/CComVariant.cpp b/modules/rostests/apitests/atl/CComVariant.cpp index 32df6f253b2..cd6cd605301 100644 --- a/modules/rostests/apitests/atl/CComVariant.cpp +++ b/modules/rostests/apitests/atl/CComVariant.cpp @@ -11,6 +11,7 @@ #include <apitest.h> #include <atlbase.h> +#include <versionhelpers.h> void expect_bool_imp(const CComVariant& ccv, bool value) { @@ -46,7 +47,8 @@ void expect_error_imp(const CComVariant& ccv, SCODE value) void expect_empty_imp(const CComVariant& ccv) { winetest_ok(V_VT(&ccv) == VT_EMPTY, "Expected .vt to be VT_EMPTY, was %u\n", V_VT(&ccv)); - winetest_ok(V_I8(&ccv) == 0ll, "Expected value to be 0, was: %I64d\n", V_I8(&ccv)); + if (IsWindows8OrGreater()) + winetest_ok(V_I8(&ccv) == 0ll, "Expected value to be 0, was: %I64d\n", V_I8(&ccv)); } #define expect_bool (winetest_set_location(__FILE__, __LINE__), 0) ? (void)0 : expect_bool_imp
5 years, 3 months
1
0
0
0
[reactos] 06/08: [PSDK] Add versionhelpers.h
by Timo Kreuzer
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=cd5cc017cb44fa341d4a7…
commit cd5cc017cb44fa341d4a7396ff5fc65f50d7fb1c Author: Timo Kreuzer <timo.kreuzer(a)reactos.org> AuthorDate: Sat Dec 7 11:33:10 2019 +0100 Commit: Timo Kreuzer <timo.kreuzer(a)reactos.org> CommitDate: Sat Dec 21 12:44:48 2019 +0100 [PSDK] Add versionhelpers.h --- sdk/include/psdk/versionhelpers.h | 156 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 156 insertions(+) diff --git a/sdk/include/psdk/versionhelpers.h b/sdk/include/psdk/versionhelpers.h new file mode 100644 index 00000000000..339a4d0cda4 --- /dev/null +++ b/sdk/include/psdk/versionhelpers.h @@ -0,0 +1,156 @@ +/* + * versionhelpers.h + * + * Inline helper functions for Windows version detection + * + * This file is part of the ReactOS PSDK package. + * + * Contributors: + * Created by Timo Kreuzer <timo.kreuzer(a)reactos.org> + * + * THIS SOFTWARE IS NOT COPYRIGHTED + * + * This source code is offered for use in the public domain. You may + * use, modify or distribute it freely. + * + * This code is distributed in the hope that it will be useful but + * WITHOUT ANY WARRANTY. ALL WARRANTIES, EXPRESS OR IMPLIED ARE HEREBY + * DISCLAMED. This includes but is not limited to warranties of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. + * + */ + +#pragma once +#define _versionhelpers_H_INCLUDED_ + +#include <specstrings.h> + +#ifdef __cplusplus +#define VERSIONHELPERAPI inline bool +#else +#define VERSIONHELPERAPI FORCEINLINE BOOL +#endif + +VERSIONHELPERAPI +IsWindowsVersionOrGreater(WORD wMajorVersion, WORD wMinorVersion, WORD wServicePackMajor) +{ + OSVERSIONINFOEXW osvi = { sizeof(osvi), wMajorVersion, wMinorVersion, 0, 0, {0}, wServicePackMajor, 0, 0, 0, 0 }; + DWORDLONG dwlConditionMask = VerSetConditionMask(0, VER_MAJORVERSION, VER_GREATER_EQUAL); + dwlConditionMask = VerSetConditionMask(dwlConditionMask, VER_MINORVERSION, VER_GREATER_EQUAL); + dwlConditionMask = VerSetConditionMask(dwlConditionMask, VER_SERVICEPACKMAJOR, VER_GREATER_EQUAL); + + return VerifyVersionInfoW(&osvi, VER_MAJORVERSION | VER_MINORVERSION | VER_SERVICEPACKMAJOR, dwlConditionMask) != FALSE; +} + +VERSIONHELPERAPI +IsWindowsXPOrGreater() +{ + return IsWindowsVersionOrGreater(5, 1, 0); +} + +VERSIONHELPERAPI +IsWindowsXPSP1OrGreater() +{ + return IsWindowsVersionOrGreater(5, 1, 1); +} + +VERSIONHELPERAPI +IsWindowsXPSP2OrGreater() +{ + return IsWindowsVersionOrGreater(5, 1, 2); +} + +VERSIONHELPERAPI +IsWindowsXPSP3OrGreater() +{ + return IsWindowsVersionOrGreater(5, 1, 3); +} + +VERSIONHELPERAPI +IsWindowsVistaOrGreater() +{ + return IsWindowsVersionOrGreater(6, 0, 0); +} + +VERSIONHELPERAPI +IsWindowsVistaSP1OrGreater() +{ + return IsWindowsVersionOrGreater(6, 0, 1); +} + +VERSIONHELPERAPI +IsWindowsVistaSP2OrGreater() +{ + return IsWindowsVersionOrGreater(6, 0, 2); +} + +VERSIONHELPERAPI +IsWindows7OrGreater() +{ + return IsWindowsVersionOrGreater(6, 1, 0); +} + +VERSIONHELPERAPI +IsWindows7SP1OrGreater() +{ + return IsWindowsVersionOrGreater(6, 1, 1); +} + +VERSIONHELPERAPI +IsWindows8OrGreater() +{ + return IsWindowsVersionOrGreater(6, 2, 0); +} + +VERSIONHELPERAPI +IsWindows8Point1OrGreater() +{ + return IsWindowsVersionOrGreater(6, 3, 0); +} + +VERSIONHELPERAPI +IsWindowsThresholdOrGreater() +{ + return IsWindowsVersionOrGreater(10, 0, 0); +} + +VERSIONHELPERAPI +IsWindows10OrGreater() +{ + return IsWindowsVersionOrGreater(10, 0, 0); +} + +VERSIONHELPERAPI +IsWindowsServer() +{ + OSVERSIONINFOEXW osvi = { sizeof(osvi), 0, 0, 0, 0, {0}, 0, 0, 0, VER_NT_WORKSTATION }; + DWORDLONG const dwlConditionMask = VerSetConditionMask(0, VER_PRODUCT_TYPE, VER_EQUAL); + return VerifyVersionInfoW(&osvi, VER_PRODUCT_TYPE, dwlConditionMask) == FALSE; +} + +VERSIONHELPERAPI +IsActiveSessionCountLimited() +{ + OSVERSIONINFOEXW osvi = { sizeof(osvi), 0, 0, 0, 0, {0}, 0, 0, 0, 0, 0 }; + DWORDLONG dwlConditionMask = VerSetConditionMask(0, VER_SUITENAME, VER_AND); + BOOL fSuiteTerminal, fSuiteSingleUserTS; + + osvi.wSuiteMask = VER_SUITE_TERMINAL; + fSuiteTerminal = VerifyVersionInfoW(&osvi, VER_SUITENAME, dwlConditionMask); + + osvi.wSuiteMask = VER_SUITE_SINGLEUSERTS; + fSuiteSingleUserTS = VerifyVersionInfoW(&osvi, VER_SUITENAME, dwlConditionMask); + + return !(fSuiteTerminal & !fSuiteSingleUserTS); +} + +#ifdef __REACTOS__ +VERSIONHELPERAPI +IsReactOS() +{ + // FIXME: Find a better method! + WCHAR szWinDir[MAX_PATH]; + GetWindowsDirectoryW(szWinDir, _countof(szWinDir)); + return (wcsstr(szWinDir, L"ReactOS") != NULL); +} +#endif // __REACTOS__
5 years, 3 months
1
0
0
0
[reactos] 05/08: [PSDK] Add extern "C" for c++ code in mmddk.h
by Timo Kreuzer
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=e6eec56a441e82e7e311a…
commit e6eec56a441e82e7e311a952970a62b0998e4d45 Author: Timo Kreuzer <timo.kreuzer(a)reactos.org> AuthorDate: Fri Nov 29 08:14:56 2019 +0100 Commit: Timo Kreuzer <timo.kreuzer(a)reactos.org> CommitDate: Sat Dec 21 12:44:48 2019 +0100 [PSDK] Add extern "C" for c++ code in mmddk.h --- sdk/include/psdk/mmddk.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/sdk/include/psdk/mmddk.h b/sdk/include/psdk/mmddk.h index fdb46d1c32a..48e7fb9ca58 100644 --- a/sdk/include/psdk/mmddk.h +++ b/sdk/include/psdk/mmddk.h @@ -29,6 +29,10 @@ #include <mmsystem.h> #include <winbase.h> +#ifdef __cplusplus +extern "C" { +#endif + /* Maxium drivers */ #define MAXWAVEDRIVERS 10 @@ -480,4 +484,8 @@ DWORD WINAPI mmGetCurrentTask(void); #include <poppack.h> +#ifdef __cplusplus +} // extern "C" +#endif + #endif /* __MMDDK_H */
5 years, 3 months
1
0
0
0
[reactos] 04/08: [GDI32_APITEST] Remove duplicated test in Test_CreateBitmap
by Timo Kreuzer
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=2dfa6f29794d28ff06754…
commit 2dfa6f29794d28ff06754266705aa5938e6c9987 Author: Timo Kreuzer <timo.kreuzer(a)reactos.org> AuthorDate: Tue Sep 19 11:17:12 2017 +0200 Commit: Timo Kreuzer <timo.kreuzer(a)reactos.org> CommitDate: Sat Dec 21 12:44:48 2019 +0100 [GDI32_APITEST] Remove duplicated test in Test_CreateBitmap --- modules/rostests/apitests/gdi32/CreateBitmap.c | 43 ++++---------------------- 1 file changed, 6 insertions(+), 37 deletions(-) diff --git a/modules/rostests/apitests/gdi32/CreateBitmap.c b/modules/rostests/apitests/gdi32/CreateBitmap.c index 4cf719feafa..3711b7b202e 100644 --- a/modules/rostests/apitests/gdi32/CreateBitmap.c +++ b/modules/rostests/apitests/gdi32/CreateBitmap.c @@ -117,7 +117,6 @@ void Test_CreateBitmap() HBITMAP hbmp; BITMAP bitmap; ULONG cjWidthBytes, cBitsPixel, cExpectedBitsPixel; - int result, TestBitsPixel, ExpectedBitsPixel; hbmp = CreateBitmap(0, 0, 0, 0, NULL); ok(hbmp != 0, "should get a 1x1 bitmap\n"); @@ -136,32 +135,6 @@ void Test_CreateBitmap() hbmp = CreateBitmap(1, 2, 1, 33, NULL); ok(hbmp == 0, "should fail\n"); - for (TestBitsPixel = 0; TestBitsPixel <= 32; TestBitsPixel++) - { - /* CreateBitmap API accepts any number as BitsPixels param. - but it can only create 1, 4, 8, 16, 24, 32 bpp bitmaps */ - if (TestBitsPixel <= 1) ExpectedBitsPixel = 1; - else if(TestBitsPixel <= 4) ExpectedBitsPixel = 4; - else if(TestBitsPixel <= 8) ExpectedBitsPixel = 8; - else if(TestBitsPixel <= 16) ExpectedBitsPixel = 16; - else if(TestBitsPixel <= 24) ExpectedBitsPixel = 24; - else if(TestBitsPixel <= 32) ExpectedBitsPixel = 32; - - /* Calculate proper bmWidthBytes */ - - hbmp = CreateBitmap(1, 2, 1, TestBitsPixel, NULL); - ok(hbmp != 0, "should get a 1x2 bitmap\n"); - result = GetObject(hbmp, sizeof(bitmap), &bitmap); - ok(result > 0, "result = %d\n", result); - ok(bitmap.bmType == 0, "bmType = %ld\n", bitmap.bmType); - ok(bitmap.bmWidth == 1, "bmWidth = %ld\n", bitmap.bmWidth); - ok(bitmap.bmHeight == 2, "bmHeight = %ld\n", bitmap.bmHeight); - ok(bitmap.bmPlanes == 1, "bmPlanes = %d\n", bitmap.bmPlanes); - ok(bitmap.bmBitsPixel == ExpectedBitsPixel, "bmBitsPixel = %d ExpectedBitsPixel= %d \n", bitmap.bmBitsPixel, ExpectedBitsPixel); - ok(bitmap.bmBits == 0, "bmBits = %p\n", bitmap.bmBits); - DeleteObject(hbmp); - } - hbmp = CreateBitmap(1, 2, 1, 1, NULL); ok(hbmp != 0, "should get a 1x2 bitmap\n"); ok_int(GetObject(hbmp, sizeof(bitmap), &bitmap), sizeof(BITMAP)); @@ -177,10 +150,10 @@ void Test_CreateBitmap() for (cBitsPixel = 0; cBitsPixel <= 32; cBitsPixel++) { /* CreateBitmap API accepts any number as BitsPixels param. - but it just can create 1, 4, 8, 16, 24, 32 bpp Bitmaps */ - if (cBitsPixel <= 1) cExpectedBitsPixel = 1; - else if (cBitsPixel <= 4) cExpectedBitsPixel = 4; - else if (cBitsPixel <= 8) cExpectedBitsPixel = 8; + but it can only create 1, 4, 8, 16, 24, 32 bpp bitmaps */ + if (cBitsPixel <= 1) cExpectedBitsPixel = 1; + else if (cBitsPixel <= 4) cExpectedBitsPixel = 4; + else if (cBitsPixel <= 8) cExpectedBitsPixel = 8; else if (cBitsPixel <= 16) cExpectedBitsPixel = 16; else if (cBitsPixel <= 24) cExpectedBitsPixel = 24; else if (cBitsPixel <= 32) cExpectedBitsPixel = 32; @@ -189,8 +162,8 @@ void Test_CreateBitmap() ok(hbmp != 0, "should get a 1x2 bitmap %ld\n", cBitsPixel); ok_int(GetObject(hbmp, sizeof(bitmap), &bitmap), sizeof(BITMAP)); - /* calculate expected line width */ - cjWidthBytes = ((((ULONG)bitmap.bmWidth) * ((ULONG)bitmap.bmBitsPixel) + 15) & ~15) >> 3; + /* Calculate expected line width */ + cjWidthBytes = ((bitmap.bmWidth * bitmap.bmBitsPixel + 15) & ~15) >> 3; ok_int(bitmap.bmType, 0); ok_int(bitmap.bmWidth, 1); @@ -200,14 +173,10 @@ void Test_CreateBitmap() ok_int(bitmap.bmWidthBytes, cjWidthBytes); ok_ptr(bitmap.bmBits, 0); DeleteObject(hbmp); - } hbmp = CreateBitmap(1, 2, 1, 33, NULL); ok(hbmp == 0, "Expected failure for 33 bpp\n"); - - - } START_TEST(CreateBitmap)
5 years, 3 months
1
0
0
0
[reactos] 03/08: [NTDLL_APITEST] Remove duplicated test for RtlInitilizeBitMap
by Timo Kreuzer
https://git.reactos.org/?p=reactos.git;a=commitdiff;h=1131d90516d894aa811e6…
commit 1131d90516d894aa811e6aac1d6a4db35c8eecc5 Author: Timo Kreuzer <timo.kreuzer(a)reactos.org> AuthorDate: Tue Dec 26 16:10:16 2017 +0100 Commit: Timo Kreuzer <timo.kreuzer(a)reactos.org> CommitDate: Sat Dec 21 12:44:48 2019 +0100 [NTDLL_APITEST] Remove duplicated test for RtlInitilizeBitMap --- modules/rostests/apitests/ntdll/CMakeLists.txt | 1 - modules/rostests/apitests/ntdll/RtlBitmap.c | 4 +++ .../rostests/apitests/ntdll/RtlInitializeBitMap.c | 41 ---------------------- modules/rostests/apitests/ntdll/testlist.c | 2 -- 4 files changed, 4 insertions(+), 44 deletions(-) diff --git a/modules/rostests/apitests/ntdll/CMakeLists.txt b/modules/rostests/apitests/ntdll/CMakeLists.txt index 8e8f2fc3897..cf0bbb4e284 100644 --- a/modules/rostests/apitests/ntdll/CMakeLists.txt +++ b/modules/rostests/apitests/ntdll/CMakeLists.txt @@ -56,7 +56,6 @@ list(APPEND SOURCE RtlGetLongestNtPathLength.c RtlHandle.c RtlImageRvaToVa.c - RtlInitializeBitMap.c RtlIsNameLegalDOS8Dot3.c RtlMemoryStream.c RtlNtPathNameToDosPathName.c diff --git a/modules/rostests/apitests/ntdll/RtlBitmap.c b/modules/rostests/apitests/ntdll/RtlBitmap.c index 82a2eff3ac5..8e7a12a51b6 100644 --- a/modules/rostests/apitests/ntdll/RtlBitmap.c +++ b/modules/rostests/apitests/ntdll/RtlBitmap.c @@ -94,6 +94,10 @@ Test_RtlInitializeBitMap(void) _SEH2_END; ok_int(Exception, 1); + RtlInitializeBitMap(&BitMapHeader, NULL, -1); + ok_int(BitMapHeader.SizeOfBitMap, -1); + ok_ptr(BitMapHeader.Buffer, NULL); + memset(Buffer, 0xcc, sizeof(Buffer)); RtlInitializeBitMap(&BitMapHeader, Buffer, 0); ok_int(BitMapHeader.SizeOfBitMap, 0); diff --git a/modules/rostests/apitests/ntdll/RtlInitializeBitMap.c b/modules/rostests/apitests/ntdll/RtlInitializeBitMap.c deleted file mode 100644 index 6dc1e193a0d..00000000000 --- a/modules/rostests/apitests/ntdll/RtlInitializeBitMap.c +++ /dev/null @@ -1,41 +0,0 @@ -/* - * PROJECT: ReactOS api tests - * LICENSE: GPL - See COPYING in the top level directory - * PURPOSE: Test for RtlInitializeBitmap - * PROGRAMMERS: Timo Kreuzer - */ - -#include "precomp.h" - -void Test_RtlInitializeBitmap() -{ - RTL_BITMAP Bitmap; - ULONG Buffer[5]; - - Buffer[0] = 0x12345; - Buffer[1] = 0x23456; - Buffer[2] = 0x34567; - Buffer[3] = 0x45678; - Buffer[4] = 0x56789; - - RtlInitializeBitMap(&Bitmap, Buffer, 19); - ok(Bitmap.Buffer == Buffer, "Buffer=%p\n", Bitmap.Buffer); - ok(Bitmap.SizeOfBitMap == 19, "SizeOfBitMap=%ld\n", Bitmap.SizeOfBitMap); - - ok(Buffer[0] == 0x12345, "Buffer[0] == 0x%lx\n", Buffer[0]); - ok(Buffer[1] == 0x23456, "Buffer[1] == 0x%lx\n", Buffer[1]); - ok(Buffer[2] == 0x34567, "Buffer[2] == 0x%lx\n", Buffer[2]); - ok(Buffer[3] == 0x45678, "Buffer[3] == 0x%lx\n", Buffer[3]); - ok(Buffer[4] == 0x56789, "Buffer[4] == 0x%lx\n", Buffer[4]); - - RtlInitializeBitMap(&Bitmap, 0, -100); - ok(Bitmap.Buffer == 0, "Buffer=%p\n", Bitmap.Buffer); - ok(Bitmap.SizeOfBitMap == -100, "SizeOfBitMap=%ld\n", Bitmap.SizeOfBitMap); - -} - -START_TEST(RtlInitializeBitMap) -{ - Test_RtlInitializeBitmap(); -} - diff --git a/modules/rostests/apitests/ntdll/testlist.c b/modules/rostests/apitests/ntdll/testlist.c index bfaf8b476fa..cfcf8cefe04 100644 --- a/modules/rostests/apitests/ntdll/testlist.c +++ b/modules/rostests/apitests/ntdll/testlist.c @@ -55,7 +55,6 @@ extern void func_RtlGetLengthWithoutTrailingPathSeperators(void); extern void func_RtlGetLongestNtPathLength(void); extern void func_RtlHandle(void); extern void func_RtlImageRvaToVa(void); -extern void func_RtlInitializeBitMap(void); extern void func_RtlIsNameLegalDOS8Dot3(void); extern void func_RtlMemoryStream(void); extern void func_RtlNtPathNameToDosPathName(void); @@ -121,7 +120,6 @@ const struct test winetest_testlist[] = { "RtlGetLongestNtPathLength", func_RtlGetLongestNtPathLength }, { "RtlHandle", func_RtlHandle }, { "RtlImageRvaToVa", func_RtlImageRvaToVa }, - { "RtlInitializeBitMap", func_RtlInitializeBitMap }, { "RtlIsNameLegalDOS8Dot3", func_RtlIsNameLegalDOS8Dot3 }, { "RtlMemoryStream", func_RtlMemoryStream }, { "RtlNtPathNameToDosPathName", func_RtlNtPathNameToDosPathName },
5 years, 3 months
1
0
0
0
← Newer
1
...
9
10
11
12
13
14
15
...
23
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
Results per page:
10
25
50
100
200