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 2010
----- 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
17 participants
467 discussions
Start a n
N
ew thread
[spetreolle] 47986: Update comctl32 base address. Avoids inetcomm related comctl32 relocations.
by spetreolle@svn.reactos.org
Author: spetreolle Date: Sat Jul 10 13:11:28 2010 New Revision: 47986 URL:
http://svn.reactos.org/svn/reactos?rev=47986&view=rev
Log: Update comctl32 base address. Avoids inetcomm related comctl32 relocations. Modified: trunk/reactos/baseaddress.rbuild Modified: trunk/reactos/baseaddress.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/baseaddress.rbuild?rev=479…
============================================================================== --- trunk/reactos/baseaddress.rbuild [iso-8859-1] (original) +++ trunk/reactos/baseaddress.rbuild [iso-8859-1] Sat Jul 10 13:11:28 2010 @@ -188,7 +188,7 @@ <property name="BASEADDRESS_RPCRT4" value="0x76000000" /> <property name="BASEADDRESS_SHLWAPI" value="0x76100000" /> <property name="BASEADDRESS_INETCOMM" value="0x76140000" /> - <property name="BASEADDRESS_COMCTL32" value="0x76160000" /> + <property name="BASEADDRESS_COMCTL32" value="0x76170000" /> <property name="BASEADDRESS_COMDLG32" value="0x76220000" /> <property name="BASEADDRESS_WINSTA" value="0x762f0000" /> <property name="BASEADDRESS_IMM32" value="0x76320000" />
14 years, 5 months
1
0
0
0
[akhaldi] 47985: [NTOS] PnpBusTypeGuidGet : Really return status. Dedicated to Richard ; )
by akhaldi@svn.reactos.org
Author: akhaldi Date: Sat Jul 10 10:34:45 2010 New Revision: 47985 URL:
http://svn.reactos.org/svn/reactos?rev=47985&view=rev
Log: [NTOS] PnpBusTypeGuidGet : Really return status. Dedicated to Richard ;) Modified: trunk/reactos/ntoskrnl/io/pnpmgr/pnpmgr.c Modified: trunk/reactos/ntoskrnl/io/pnpmgr/pnpmgr.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/io/pnpmgr/pnpmgr.…
============================================================================== --- trunk/reactos/ntoskrnl/io/pnpmgr/pnpmgr.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/io/pnpmgr/pnpmgr.c [iso-8859-1] Sat Jul 10 10:34:45 2010 @@ -3027,7 +3027,7 @@ /* Release lock and return status */ ExReleaseFastMutex(&PnpBusTypeGuidList->Lock); - return Index; + return Status; } NTSTATUS
14 years, 5 months
1
0
0
0
[fireball] 47984: - Fix build.
by fireball@svn.reactos.org
Author: fireball Date: Fri Jul 9 22:31:56 2010 New Revision: 47984 URL:
http://svn.reactos.org/svn/reactos?rev=47984&view=rev
Log: - Fix build. Modified: branches/arwinss/reactos/subsystems/win32/win32k/include/win32kp.h Modified: branches/arwinss/reactos/subsystems/win32/win32k/include/win32kp.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
============================================================================== --- branches/arwinss/reactos/subsystems/win32/win32k/include/win32kp.h [iso-8859-1] (original) +++ branches/arwinss/reactos/subsystems/win32/win32k/include/win32kp.h [iso-8859-1] Fri Jul 9 22:31:56 2010 @@ -44,7 +44,7 @@ #include <surfobj.h> #include <cursor.h> #include <devobj.h> -#include <brushobj.h> +#include <brush.h> #include <swm.h> #include <dc.h> #include <palobj.h>
14 years, 5 months
1
0
0
0
[spetreolle] 47983: Forgot to svn add this in previous commit, my bad.
by spetreolle@svn.reactos.org
Author: spetreolle Date: Fri Jul 9 21:05:01 2010 New Revision: 47983 URL:
http://svn.reactos.org/svn/reactos?rev=47983&view=rev
Log: Forgot to svn add this in previous commit, my bad. Added: trunk/reactos/dll/win32/dnsapi/dnsapi/record.c (with props) Added: trunk/reactos/dll/win32/dnsapi/dnsapi/record.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/dnsapi/dnsapi/re…
============================================================================== --- trunk/reactos/dll/win32/dnsapi/dnsapi/record.c (added) +++ trunk/reactos/dll/win32/dnsapi/dnsapi/record.c [iso-8859-1] Fri Jul 9 21:05:01 2010 @@ -1,0 +1,750 @@ +/* + * DNS support + * + * Copyright (C) 2006 Hans Leidekker + * + * 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 + */ +#include "precomp.h" + +#define NDEBUG +#include <debug.h> + +const char *dns_type_to_str( unsigned short type ) +{ + switch (type) + { +#define X(x) case (x): return #x; + X(DNS_TYPE_ZERO) + X(DNS_TYPE_A) + X(DNS_TYPE_NS) + X(DNS_TYPE_MD) + X(DNS_TYPE_MF) + X(DNS_TYPE_CNAME) + X(DNS_TYPE_SOA) + X(DNS_TYPE_MB) + X(DNS_TYPE_MG) + X(DNS_TYPE_MR) + X(DNS_TYPE_NULL) + X(DNS_TYPE_WKS) + X(DNS_TYPE_PTR) + X(DNS_TYPE_HINFO) + X(DNS_TYPE_MINFO) + X(DNS_TYPE_MX) + X(DNS_TYPE_TEXT) + X(DNS_TYPE_RP) + X(DNS_TYPE_AFSDB) + X(DNS_TYPE_X25) + X(DNS_TYPE_ISDN) + X(DNS_TYPE_RT) + X(DNS_TYPE_NSAP) + X(DNS_TYPE_NSAPPTR) + X(DNS_TYPE_SIG) + X(DNS_TYPE_KEY) + X(DNS_TYPE_PX) + X(DNS_TYPE_GPOS) + X(DNS_TYPE_AAAA) + X(DNS_TYPE_LOC) + X(DNS_TYPE_NXT) + X(DNS_TYPE_EID) + X(DNS_TYPE_NIMLOC) + X(DNS_TYPE_SRV) + X(DNS_TYPE_ATMA) + X(DNS_TYPE_NAPTR) + X(DNS_TYPE_KX) + X(DNS_TYPE_CERT) + X(DNS_TYPE_A6) + X(DNS_TYPE_DNAME) + X(DNS_TYPE_SINK) + X(DNS_TYPE_OPT) + X(DNS_TYPE_UINFO) + X(DNS_TYPE_UID) + X(DNS_TYPE_GID) + X(DNS_TYPE_UNSPEC) + X(DNS_TYPE_ADDRS) + X(DNS_TYPE_TKEY) + X(DNS_TYPE_TSIG) + X(DNS_TYPE_IXFR) + X(DNS_TYPE_AXFR) + X(DNS_TYPE_MAILB) + X(DNS_TYPE_MAILA) + X(DNS_TYPE_ANY) + X(DNS_TYPE_WINS) + X(DNS_TYPE_WINSR) +#undef X + default: { static char tmp[7]; sprintf( tmp, "0x%04x", type ); return tmp; } + } +} + +static int dns_strcmpX( LPCVOID str1, LPCVOID str2, BOOL wide ) +{ + if (wide) + return lstrcmpiW( str1, str2 ); + else + return lstrcmpiA( str1, str2 ); +} + +/****************************************************************************** + * DnsRecordCompare [DNSAPI.@] + * + */ +BOOL WINAPI DnsRecordCompare( PDNS_RECORD r1, PDNS_RECORD r2 ) +{ + BOOL wide; + unsigned int i; + + DPRINT( "(%p,%p)\n", r1, r2 ); + + if (r1->wType != r2->wType || + r1->wDataLength != r2->wDataLength || + r1->Flags.DW != r2->Flags.DW || + r1->dwReserved != r2->dwReserved) return FALSE; + + wide = (r1->Flags.S.CharSet == DnsCharSetUnicode) ? TRUE : FALSE; + if (dns_strcmpX( r1->pName, r2->pName, wide )) return FALSE; + + switch (r1->wType) + { + case DNS_TYPE_A: + { + if (r1->Data.A.IpAddress != r2->Data.A.IpAddress) return FALSE; + break; + } + case DNS_TYPE_SOA: + { + if (r1->Data.SOA.dwSerialNo != r2->Data.SOA.dwSerialNo || + r1->Data.SOA.dwRefresh != r2->Data.SOA.dwRefresh || + r1->Data.SOA.dwRetry != r2->Data.SOA.dwRetry || + r1->Data.SOA.dwExpire != r2->Data.SOA.dwExpire || + r1->Data.SOA.dwDefaultTtl != r2->Data.SOA.dwDefaultTtl) + return FALSE; + if (dns_strcmpX( r1->Data.SOA.pNamePrimaryServer, + r2->Data.SOA.pNamePrimaryServer, wide ) || + dns_strcmpX( r1->Data.SOA.pNameAdministrator, + r2->Data.SOA.pNameAdministrator, wide )) + return FALSE; + break; + } + case DNS_TYPE_PTR: + case DNS_TYPE_NS: + case DNS_TYPE_CNAME: + case DNS_TYPE_MB: + case DNS_TYPE_MD: + case DNS_TYPE_MF: + case DNS_TYPE_MG: + case DNS_TYPE_MR: + { + if (dns_strcmpX( r1->Data.PTR.pNameHost, + r2->Data.PTR.pNameHost, wide )) return FALSE; + break; + } + case DNS_TYPE_MINFO: + case DNS_TYPE_RP: + { + if (dns_strcmpX( r1->Data.MINFO.pNameMailbox, + r2->Data.MINFO.pNameMailbox, wide ) || + dns_strcmpX( r1->Data.MINFO.pNameErrorsMailbox, + r2->Data.MINFO.pNameErrorsMailbox, wide )) + return FALSE; + break; + } + case DNS_TYPE_MX: + case DNS_TYPE_AFSDB: + case DNS_TYPE_RT: + { + if (r1->Data.MX.wPreference != r2->Data.MX.wPreference) + return FALSE; + if (dns_strcmpX( r1->Data.MX.pNameExchange, + r2->Data.MX.pNameExchange, wide )) + return FALSE; + break; + } + case DNS_TYPE_HINFO: + case DNS_TYPE_ISDN: + case DNS_TYPE_TEXT: + case DNS_TYPE_X25: + { + if (r1->Data.TXT.dwStringCount != r2->Data.TXT.dwStringCount) + return FALSE; + for (i = 0; i < r1->Data.TXT.dwStringCount; i++) + { + if (dns_strcmpX( r1->Data.TXT.pStringArray[i], + r2->Data.TXT.pStringArray[i], wide )) + return FALSE; + } + break; + } + case DNS_TYPE_NULL: + { + if (r1->Data.Null.dwByteCount != r2->Data.Null.dwByteCount) + return FALSE; + if (memcmp( r1->Data.Null.Data, + r2->Data.Null.Data, r1->Data.Null.dwByteCount )) + return FALSE; + break; + } + case DNS_TYPE_AAAA: + { + for (i = 0; i < sizeof(IP6_ADDRESS)/sizeof(DWORD); i++) + { + if (r1->Data.AAAA.Ip6Address.IP6Dword[i] != + r2->Data.AAAA.Ip6Address.IP6Dword[i]) return FALSE; + } + break; + } + case DNS_TYPE_KEY: + { + if (r1->Data.KEY.wFlags != r2->Data.KEY.wFlags || + r1->Data.KEY.chProtocol != r2->Data.KEY.chProtocol || + r1->Data.KEY.chAlgorithm != r2->Data.KEY.chAlgorithm) + return FALSE; + if (memcmp( r1->Data.KEY.Key, r2->Data.KEY.Key, + r1->wDataLength - sizeof(DNS_KEY_DATA) + 1 )) + return FALSE; + break; + } + case DNS_TYPE_SIG: + { + if (dns_strcmpX( r1->Data.SIG.pNameSigner, + r2->Data.SIG.pNameSigner, wide )) + return FALSE; + if (r1->Data.SIG.wTypeCovered != r2->Data.SIG.wTypeCovered || + r1->Data.SIG.chAlgorithm != r2->Data.SIG.chAlgorithm || + r1->Data.SIG.chLabelCount != r2->Data.SIG.chLabelCount || + r1->Data.SIG.dwOriginalTtl != r2->Data.SIG.dwOriginalTtl || + r1->Data.SIG.dwExpiration != r2->Data.SIG.dwExpiration || + r1->Data.SIG.dwTimeSigned != r2->Data.SIG.dwTimeSigned || + r1->Data.SIG.wKeyTag != r2->Data.SIG.wKeyTag) + return FALSE; + if (memcmp( r1->Data.SIG.Signature, r2->Data.SIG.Signature, + r1->wDataLength - sizeof(DNS_SIG_DATAA) + 1 )) + return FALSE; + break; + } + case DNS_TYPE_ATMA: + { + if (r1->Data.ATMA.AddressType != r2->Data.ATMA.AddressType) + return FALSE; + for (i = 0; i < DNS_ATMA_MAX_ADDR_LENGTH; i++) + { + if (r1->Data.ATMA.Address[i] != r2->Data.ATMA.Address[i]) + return FALSE; + } + break; + } + case DNS_TYPE_NXT: + { + if (dns_strcmpX( r1->Data.NXT.pNameNext, + r2->Data.NXT.pNameNext, wide )) return FALSE; + if (r1->Data.NXT.wNumTypes != r2->Data.NXT.wNumTypes) return FALSE; + if (memcmp( r1->Data.NXT.wTypes, r2->Data.NXT.wTypes, + r1->wDataLength - sizeof(DNS_NXT_DATAA) + sizeof(WORD) )) + return FALSE; + break; + } + case DNS_TYPE_SRV: + { + if (dns_strcmpX( r1->Data.SRV.pNameTarget, + r2->Data.SRV.pNameTarget, wide )) return FALSE; + if (r1->Data.SRV.wPriority != r2->Data.SRV.wPriority || + r1->Data.SRV.wWeight != r2->Data.SRV.wWeight || + r1->Data.SRV.wPort != r2->Data.SRV.wPort) + return FALSE; + break; + } + case DNS_TYPE_TKEY: + { + if (dns_strcmpX( r1->Data.TKEY.pNameAlgorithm, + r2->Data.TKEY.pNameAlgorithm, wide )) + return FALSE; + if (r1->Data.TKEY.dwCreateTime != r2->Data.TKEY.dwCreateTime || + r1->Data.TKEY.dwExpireTime != r2->Data.TKEY.dwExpireTime || + r1->Data.TKEY.wMode != r2->Data.TKEY.wMode || + r1->Data.TKEY.wError != r2->Data.TKEY.wError || + r1->Data.TKEY.wKeyLength != r2->Data.TKEY.wKeyLength || + r1->Data.TKEY.wOtherLength != r2->Data.TKEY.wOtherLength || + r1->Data.TKEY.cAlgNameLength != r2->Data.TKEY.cAlgNameLength || + r1->Data.TKEY.bPacketPointers != r2->Data.TKEY.bPacketPointers) + return FALSE; + + /* FIXME: ignoring pAlgorithmPacket field */ + if (memcmp( r1->Data.TKEY.pKey, r2->Data.TKEY.pKey, + r1->Data.TKEY.wKeyLength ) || + memcmp( r1->Data.TKEY.pOtherData, r2->Data.TKEY.pOtherData, + r1->Data.TKEY.wOtherLength )) return FALSE; + break; + } + case DNS_TYPE_TSIG: + { + if (dns_strcmpX( r1->Data.TSIG.pNameAlgorithm, + r2->Data.TSIG.pNameAlgorithm, wide )) + return FALSE; + if (r1->Data.TSIG.i64CreateTime != r2->Data.TSIG.i64CreateTime || + r1->Data.TSIG.wFudgeTime != r2->Data.TSIG.wFudgeTime || + r1->Data.TSIG.wOriginalXid != r2->Data.TSIG.wOriginalXid || + r1->Data.TSIG.wError != r2->Data.TSIG.wError || + r1->Data.TSIG.wSigLength != r2->Data.TSIG.wSigLength || + r1->Data.TSIG.wOtherLength != r2->Data.TSIG.wOtherLength || + r1->Data.TSIG.cAlgNameLength != r2->Data.TSIG.cAlgNameLength || + r1->Data.TSIG.bPacketPointers != r2->Data.TSIG.bPacketPointers) + return FALSE; + + /* FIXME: ignoring pAlgorithmPacket field */ + if (memcmp( r1->Data.TSIG.pSignature, r2->Data.TSIG.pSignature, + r1->Data.TSIG.wSigLength ) || + memcmp( r1->Data.TSIG.pOtherData, r2->Data.TSIG.pOtherData, + r1->Data.TSIG.wOtherLength )) return FALSE; + break; + } + case DNS_TYPE_WINS: + { + if (r1->Data.WINS.dwMappingFlag != r2->Data.WINS.dwMappingFlag || + r1->Data.WINS.dwLookupTimeout != r2->Data.WINS.dwLookupTimeout || + r1->Data.WINS.dwCacheTimeout != r2->Data.WINS.dwCacheTimeout || + r1->Data.WINS.cWinsServerCount != r2->Data.WINS.cWinsServerCount) + return FALSE; + if (memcmp( r1->Data.WINS.WinsServers, r2->Data.WINS.WinsServers, + r1->wDataLength - sizeof(DNS_WINS_DATA) + sizeof(IP4_ADDRESS) )) + return FALSE; + break; + } + case DNS_TYPE_WINSR: + { + if (r1->Data.WINSR.dwMappingFlag != r2->Data.WINSR.dwMappingFlag || + r1->Data.WINSR.dwLookupTimeout != r2->Data.WINSR.dwLookupTimeout || + r1->Data.WINSR.dwCacheTimeout != r2->Data.WINSR.dwCacheTimeout) + return FALSE; + if (dns_strcmpX( r1->Data.WINSR.pNameResultDomain, + r2->Data.WINSR.pNameResultDomain, wide )) + return FALSE; + break; + } + default: + DPRINT1( "unknown type: %s\n", dns_type_to_str( r1->wType ) ); + return FALSE; + } + return TRUE; +} + +static LPVOID dns_strcpyX( LPCVOID src, DNS_CHARSET in, DNS_CHARSET out ) +{ + switch (in) + { + case DnsCharSetUnicode: + { + switch (out) + { + case DnsCharSetUnicode: return dns_strdup_w( src ); + case DnsCharSetUtf8: return dns_strdup_wu( src ); + case DnsCharSetAnsi: return dns_strdup_wa( src ); + default: + DPRINT1( "unhandled target charset: %d\n", out ); + break; + } + } + case DnsCharSetUtf8: + switch (out) + { + case DnsCharSetUnicode: return dns_strdup_uw( src ); + case DnsCharSetUtf8: return dns_strdup_u( src ); + case DnsCharSetAnsi: return dns_strdup_ua( src ); + default: + DPRINT1( "unhandled target charset: %d\n", out ); + break; + } + case DnsCharSetAnsi: + switch (out) + { + case DnsCharSetUnicode: return dns_strdup_aw( src ); + case DnsCharSetUtf8: return dns_strdup_au( src ); + case DnsCharSetAnsi: return dns_strdup_a( src ); + default: + DPRINT1( "unhandled target charset: %d\n", out ); + break; + } + default: + DPRINT1( "unhandled source charset: %d\n", in ); + break; + } + return NULL; +} + +/****************************************************************************** + * DnsRecordCopyEx [DNSAPI.@] + * + */ +PDNS_RECORD WINAPI DnsRecordCopyEx( PDNS_RECORD src, DNS_CHARSET in, DNS_CHARSET out ) +{ + DNS_RECORD *dst; + unsigned int i, size; + + DPRINT( "(%p,%d,%d)\n", src, in, out ); + + size = FIELD_OFFSET(DNS_RECORD, Data) + src->wDataLength; + dst = HeapAlloc( GetProcessHeap(), HEAP_ZERO_MEMORY, size ); + if (!dst) return NULL; + + memcpy( dst, src, size ); + + if (src->Flags.S.CharSet == DnsCharSetUtf8 || + src->Flags.S.CharSet == DnsCharSetAnsi || + src->Flags.S.CharSet == DnsCharSetUnicode) in = src->Flags.S.CharSet; + + dst->Flags.S.CharSet = out; + dst->pName = dns_strcpyX( src->pName, in, out ); + if (!dst->pName) goto error; + + switch (src->wType) + { + case DNS_TYPE_HINFO: + case DNS_TYPE_ISDN: + case DNS_TYPE_TEXT: + case DNS_TYPE_X25: + { + for (i = 0; i < src->Data.TXT.dwStringCount; i++) + { + dst->Data.TXT.pStringArray[i] = + dns_strcpyX( src->Data.TXT.pStringArray[i], in, out ); + + if (!dst->Data.TXT.pStringArray[i]) + { + while (i > 0) HeapFree( GetProcessHeap(), 0, dst->Data.TXT.pStringArray[--i] ); + goto error; + } + } + break; + } + case DNS_TYPE_MINFO: + case DNS_TYPE_RP: + { + dst->Data.MINFO.pNameMailbox = + dns_strcpyX( src->Data.MINFO.pNameMailbox, in, out ); + if (!dst->Data.MINFO.pNameMailbox) goto error; + + dst->Data.MINFO.pNameErrorsMailbox = + dns_strcpyX( src->Data.MINFO.pNameErrorsMailbox, in, out ); + if (!dst->Data.MINFO.pNameErrorsMailbox) + { + HeapFree( GetProcessHeap(), 0, dst->Data.MINFO.pNameMailbox ); + goto error; + } + break; + } + case DNS_TYPE_AFSDB: + case DNS_TYPE_RT: + case DNS_TYPE_MX: + { + dst->Data.MX.pNameExchange = + dns_strcpyX( src->Data.MX.pNameExchange, in, out ); + if (!dst->Data.MX.pNameExchange) goto error; + break; + } + case DNS_TYPE_NXT: + { + dst->Data.NXT.pNameNext = + dns_strcpyX( src->Data.NXT.pNameNext, in, out ); + if (!dst->Data.NXT.pNameNext) goto error; + break; + } + case DNS_TYPE_CNAME: + case DNS_TYPE_MB: + case DNS_TYPE_MD: + case DNS_TYPE_MF: + case DNS_TYPE_MG: + case DNS_TYPE_MR: + case DNS_TYPE_NS: + case DNS_TYPE_PTR: + { + dst->Data.PTR.pNameHost = + dns_strcpyX( src->Data.PTR.pNameHost, in, out ); + if (!dst->Data.PTR.pNameHost) goto error; + break; + } + case DNS_TYPE_SIG: + { + dst->Data.SIG.pNameSigner = + dns_strcpyX( src->Data.SIG.pNameSigner, in, out ); + if (!dst->Data.SIG.pNameSigner) goto error; + break; + } + case DNS_TYPE_SOA: + { + dst->Data.SOA.pNamePrimaryServer = + dns_strcpyX( src->Data.SOA.pNamePrimaryServer, in, out ); + if (!dst->Data.SOA.pNamePrimaryServer) goto error; + + dst->Data.SOA.pNameAdministrator = + dns_strcpyX( src->Data.SOA.pNameAdministrator, in, out ); + if (!dst->Data.SOA.pNameAdministrator) + { + HeapFree( GetProcessHeap(), 0, dst->Data.SOA.pNamePrimaryServer ); + goto error; + } + break; + } + case DNS_TYPE_SRV: + { + dst->Data.SRV.pNameTarget = + dns_strcpyX( src->Data.SRV.pNameTarget, in, out ); + if (!dst->Data.SRV.pNameTarget) goto error; + break; + } + default: + break; + } + return dst; + +error: + HeapFree( GetProcessHeap(), 0, dst->pName ); + HeapFree( GetProcessHeap(), 0, dst ); + return NULL; +} + +/****************************************************************************** + * DnsRecordListFree [DNSAPI.@] + * + */ +VOID WINAPI DnsRecordListFree( PDNS_RECORD list, DNS_FREE_TYPE type ) +{ + DNS_RECORD *r, *next; + unsigned int i; + + DPRINT( "(%p,%d)\n", list, type ); + + if (!list) return; + + switch (type) + { + case DnsFreeRecordList: + { + for (r = list; (list = r); r = next) + { + HeapFree( GetProcessHeap(), 0, r->pName ); + + switch (r->wType) + { + case DNS_TYPE_HINFO: + case DNS_TYPE_ISDN: + case DNS_TYPE_TEXT: + case DNS_TYPE_X25: + { + for (i = 0; i < r->Data.TXT.dwStringCount; i++) + HeapFree( GetProcessHeap(), 0, r->Data.TXT.pStringArray[i] ); + + break; + } + case DNS_TYPE_MINFO: + case DNS_TYPE_RP: + { + HeapFree( GetProcessHeap(), 0, r->Data.MINFO.pNameMailbox ); + HeapFree( GetProcessHeap(), 0, r->Data.MINFO.pNameErrorsMailbox ); + break; + } + case DNS_TYPE_AFSDB: + case DNS_TYPE_RT: + case DNS_TYPE_MX: + { + HeapFree( GetProcessHeap(), 0, r->Data.MX.pNameExchange ); + break; + } + case DNS_TYPE_NXT: + { + HeapFree( GetProcessHeap(), 0, r->Data.NXT.pNameNext ); + break; + } + case DNS_TYPE_CNAME: + case DNS_TYPE_MB: + case DNS_TYPE_MD: + case DNS_TYPE_MF: + case DNS_TYPE_MG: + case DNS_TYPE_MR: + case DNS_TYPE_NS: + case DNS_TYPE_PTR: + { + HeapFree( GetProcessHeap(), 0, r->Data.PTR.pNameHost ); + break; + } + case DNS_TYPE_SIG: + { + HeapFree( GetProcessHeap(), 0, r->Data.SIG.pNameSigner ); + break; + } + case DNS_TYPE_SOA: + { + HeapFree( GetProcessHeap(), 0, r->Data.SOA.pNamePrimaryServer ); + HeapFree( GetProcessHeap(), 0, r->Data.SOA.pNameAdministrator ); + break; + } + case DNS_TYPE_SRV: + { + HeapFree( GetProcessHeap(), 0, r->Data.SRV.pNameTarget ); + break; + } + default: + break; + } + + next = r->pNext; + HeapFree( GetProcessHeap(), 0, r ); + } + break; + } + case DnsFreeFlat: + case DnsFreeParsedMessageFields: + { + DPRINT1( "unhandled free type: %d\n", type ); + break; + } + default: + DPRINT1( "unknown free type: %d\n", type ); + break; + } +} + +/****************************************************************************** + * DnsRecordSetCompare [DNSAPI.@] + * + */ +BOOL WINAPI DnsRecordSetCompare( PDNS_RECORD set1, PDNS_RECORD set2, + PDNS_RECORD *diff1, PDNS_RECORD *diff2 ) +{ + BOOL ret = TRUE; + DNS_RECORD *r, *t, *u; + DNS_RRSET rr1, rr2; + + DPRINT( "(%p,%p,%p,%p)\n", set1, set2, diff1, diff2 ); + + if (!set1 && !set2) return FALSE; + + if (diff1) *diff1 = NULL; + if (diff2) *diff2 = NULL; + + if (set1 && !set2) + { + if (diff1) *diff1 = DnsRecordSetCopyEx( set1, 0, set1->Flags.S.CharSet ); + return FALSE; + } + if (!set1 && set2) + { + if (diff2) *diff2 = DnsRecordSetCopyEx( set2, 0, set2->Flags.S.CharSet ); + return FALSE; + } + + DNS_RRSET_INIT( rr1 ); + DNS_RRSET_INIT( rr2 ); + + for (r = set1; r; r = r->pNext) + { + for (t = set2; t; t = t->pNext) + { + u = DnsRecordCopyEx( r, r->Flags.S.CharSet, t->Flags.S.CharSet ); + if (!u) goto error; + + if (!DnsRecordCompare( t, u )) + { + DNS_RRSET_ADD( rr1, u ); + ret = FALSE; + } + else DnsRecordListFree( u, DnsFreeRecordList ); + } + } + + for (t = set2; t; t = t->pNext) + { + for (r = set1; r; r = r->pNext) + { + u = DnsRecordCopyEx( t, t->Flags.S.CharSet, r->Flags.S.CharSet ); + if (!u) goto error; + + if (!DnsRecordCompare( r, u )) + { + DNS_RRSET_ADD( rr2, u ); + ret = FALSE; + } + else DnsRecordListFree( u, DnsFreeRecordList ); + } + } + + DNS_RRSET_TERMINATE( rr1 ); + DNS_RRSET_TERMINATE( rr2 ); + + if (diff1) *diff1 = rr1.pFirstRR; + else DnsRecordListFree( rr1.pFirstRR, DnsFreeRecordList ); + + if (diff2) *diff2 = rr2.pFirstRR; + else DnsRecordListFree( rr2.pFirstRR, DnsFreeRecordList ); + + return ret; + +error: + DNS_RRSET_TERMINATE( rr1 ); + DNS_RRSET_TERMINATE( rr2 ); + + DnsRecordListFree( rr1.pFirstRR, DnsFreeRecordList ); + DnsRecordListFree( rr2.pFirstRR, DnsFreeRecordList ); + + return FALSE; +} + +/****************************************************************************** + * DnsRecordSetCopyEx [DNSAPI.@] + * + */ +PDNS_RECORD WINAPI DnsRecordSetCopyEx( PDNS_RECORD src_set, DNS_CHARSET in, DNS_CHARSET out ) +{ + DNS_RRSET dst_set; + DNS_RECORD *src, *dst; + + DPRINT( "(%p,%d,%d)\n", src_set, in, out ); + + DNS_RRSET_INIT( dst_set ); + + for (src = src_set; (src_set = src); src = src_set->pNext) + { + dst = DnsRecordCopyEx( src, in, out ); + if (!dst) + { + DNS_RRSET_TERMINATE( dst_set ); + DnsRecordListFree( dst_set.pFirstRR, DnsFreeRecordList ); + return NULL; + } + DNS_RRSET_ADD( dst_set, dst ); + } + + DNS_RRSET_TERMINATE( dst_set ); + return dst_set.pFirstRR; +} + +/****************************************************************************** + * DnsRecordSetDetach [DNSAPI.@] + * + */ +PDNS_RECORD WINAPI DnsRecordSetDetach( PDNS_RECORD set ) +{ + DNS_RECORD *r, *s; + + DPRINT( "(%p)\n", set ); + + for (r = set; (set = r); r = set->pNext) + { + if (r->pNext && !r->pNext->pNext) + { + s = r->pNext; + r->pNext = NULL; + return s; + } + } + return NULL; +} Propchange: trunk/reactos/dll/win32/dnsapi/dnsapi/record.c ------------------------------------------------------------------------------ svn:eol-style = native
14 years, 5 months
1
0
0
0
[spetreolle] 47982: Import DnsNameCompare, DnsValidateName, DnsRecord* functions from Wine. Fixes dnsapi:name tests. Patch by Samuel Serapion.
by spetreolle@svn.reactos.org
Author: spetreolle Date: Fri Jul 9 20:56:12 2010 New Revision: 47982 URL:
http://svn.reactos.org/svn/reactos?rev=47982&view=rev
Log: Import DnsNameCompare, DnsValidateName, DnsRecord* functions from Wine. Fixes dnsapi:name tests. Patch by Samuel Serapion. Modified: trunk/reactos/dll/win32/dnsapi/dnsapi.rbuild trunk/reactos/dll/win32/dnsapi/dnsapi/free.c trunk/reactos/dll/win32/dnsapi/dnsapi/names.c trunk/reactos/dll/win32/dnsapi/dnsapi/precomp.h trunk/reactos/dll/win32/dnsapi/dnsapi/stubs.c trunk/reactos/include/psdk/windns.h Modified: trunk/reactos/dll/win32/dnsapi/dnsapi.rbuild URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/dnsapi/dnsapi.rb…
============================================================================== --- trunk/reactos/dll/win32/dnsapi/dnsapi.rbuild [iso-8859-1] (original) +++ trunk/reactos/dll/win32/dnsapi/dnsapi.rbuild [iso-8859-1] Fri Jul 9 20:56:12 2010 @@ -15,6 +15,7 @@ <file>free.c</file> <file>names.c</file> <file>query.c</file> + <file>record.c</file> <file>stubs.c</file> <pch>precomp.h</pch> </directory> Modified: trunk/reactos/dll/win32/dnsapi/dnsapi/free.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/dnsapi/dnsapi/fr…
============================================================================== --- trunk/reactos/dll/win32/dnsapi/dnsapi/free.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/dnsapi/dnsapi/free.c [iso-8859-1] Fri Jul 9 20:56:12 2010 @@ -33,9 +33,3 @@ } } -VOID WINAPI -DnsRecordListFree(PDNS_RECORD Data, - DNS_FREE_TYPE FreeType) -{ - DnsFree(Data, FreeType); -} Modified: trunk/reactos/dll/win32/dnsapi/dnsapi/names.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/dnsapi/dnsapi/na…
============================================================================== --- trunk/reactos/dll/win32/dnsapi/dnsapi/names.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/dnsapi/dnsapi/names.c [iso-8859-1] Fri Jul 9 20:56:12 2010 @@ -1,218 +1,234 @@ +/* + * DNS support + * + * Copyright (C) 2006 Matthew Kehrer + * Copyright (C) 2006 Hans Leidekker + * + * 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 + */ + #include "precomp.h" #define NDEBUG #include <debug.h> -static BOOL -DnsIntNameContainsDots(LPCWSTR Name) -{ - return wcschr(Name, '.') ? TRUE : FALSE; -} - -static BOOL -DnsIntTwoConsecutiveDots(LPCWSTR Name) -{ - return wcsstr(Name, L"..") ? TRUE : FALSE; -} - -static BOOL -DnsIntContainsUnderscore(LPCWSTR Name) -{ - return wcschr(Name, '_') ? TRUE : FALSE; -} - -/* DnsValidateName ********************* - * Use some different algorithms to validate the given name as suitable for - * use with DNS. - * - * Name -- The name to evaluate. - * Format -- Format to use: - * DnsNameDomain - * DnsNameDomainLabel - * DnsNameHostnameFull - * DnsNameHostnameLabel - * DnsNameWildcard - * DnsNameSrvRecord - * RETURNS: - * ERROR_SUCCESS -- All good - * ERROR_INVALID_NAME -- - * Name greater than 255 chars. - * Label greater than 63 chars. - * Two consecutive dots, or starts with dot. - * Contains a dot, but a Label check was specified. - * DNS_ERROR_INVALID_NAME_CHAR - * Contains any invalid char: " {|}~[\]^':;<=>?@!"#$%^`()+/," - * Contains an *, except when it is the first label and Wildcard was - * specified. - * DNS_ERROR_NUMERIC_NAME - * Set if the name contains only numerics, unless Domain is specified. - * DNS_ERROR_NON_RFC_NAME - * If the name contains underscore. - * If there is an underscore in any position but the first in the SrvRecord - * case. - * If the name contains a non-ascii character. - */ - -DNS_STATUS WINAPI -DnsValidateName_W(LPCWSTR Name, - DNS_NAME_FORMAT Format) -{ - BOOL AllowDot = FALSE; - BOOL AllowLeadingAst = FALSE; - BOOL AllowLeadingUnderscore = FALSE; - BOOL AllowAllDigits = FALSE; - const WCHAR *NextLabel, *CurrentLabel, *CurrentChar; - - switch(Format) - { - case DnsNameDomain: - AllowAllDigits = TRUE; - AllowDot = TRUE; - break; - - case DnsNameDomainLabel: - AllowAllDigits = TRUE; - break; - - case DnsNameHostnameFull: - AllowDot = TRUE; - break; - - case DnsNameHostnameLabel: - break; - - case DnsNameWildcard: - AllowLeadingAst = TRUE; - AllowDot = TRUE; - break; - - case DnsNameSrvRecord: - AllowLeadingUnderscore = TRUE; - break; - - default: - break; - } - - /* Preliminary checks */ - if(Name[0] == 0) - return ERROR_INVALID_NAME; /* XXX arty: Check this */ - - /* Name too long */ - if(wcslen(Name) > 255) - return ERROR_INVALID_NAME; - - /* Violations about dots */ - if((!AllowDot && DnsIntNameContainsDots(Name)) || Name[0] == '.' || DnsIntTwoConsecutiveDots(Name)) - return ERROR_INVALID_NAME; - - /* Check component sizes */ - CurrentLabel = Name; - - do - { - NextLabel = CurrentLabel; - while(*NextLabel && *NextLabel != '.') - NextLabel++; - - if(NextLabel - CurrentLabel > 63) +/****************************************************************************** + * DnsNameCompare_A [DNSAPI.@] + * + */ +BOOL WINAPI DnsNameCompare_A( LPCSTR name1, LPCSTR name2 ) +{ + BOOL ret; + PWSTR name1W, name2W; + + name1W = dns_strdup_aw( name1 ); + name2W = dns_strdup_aw( name2 ); + + ret = DnsNameCompare_W( name1W, name2W ); + + HeapFree(GetProcessHeap(), 0, name1W ); + HeapFree(GetProcessHeap(), 0, name2W ); + + return ret; +} + +/****************************************************************************** + * DnsNameCompare_W [DNSAPI.@] + * + */ +BOOL WINAPI DnsNameCompare_W( PCWSTR name1, PCWSTR name2 ) +{ + PCWSTR p, q; + + if (!name1 && !name2) return TRUE; + if (!name1 || !name2) return FALSE; + + p = name1 + lstrlenW( name1 ) - 1; + q = name2 + lstrlenW( name2 ) - 1; + + while (*p == '.' && p >= name1) p--; + while (*q == '.' && q >= name2) q--; + + if (p - name1 != q - name2) return FALSE; + + while (name1 <= p) + { + if (towupper( *name1 ) != towupper( *name2 )) + return FALSE; + + name1++; + name2++; + } + return TRUE; +} + +/****************************************************************************** + * DnsValidateName_A [DNSAPI.@] + * + */ +DNS_STATUS WINAPI DnsValidateName_A( PCSTR name, DNS_NAME_FORMAT format ) +{ + PWSTR nameW; + DNS_STATUS ret; + + nameW = dns_strdup_aw( name ); + ret = DnsValidateName_W( nameW, format ); + + HeapFree(GetProcessHeap(), 0, nameW ); + return ret; +} + +/****************************************************************************** + * DnsValidateName_UTF8 [DNSAPI.@] + * + */ +DNS_STATUS WINAPI DnsValidateName_UTF8( PCSTR name, DNS_NAME_FORMAT format ) +{ + PWSTR nameW; + DNS_STATUS ret; + + nameW = dns_strdup_uw( name ); + ret = DnsValidateName_W( nameW, format ); + + HeapFree(GetProcessHeap(), 0, nameW ); + return ret; +} + +#define HAS_EXTENDED 0x0001 +#define HAS_NUMERIC 0x0002 +#define HAS_NON_NUMERIC 0x0004 +#define HAS_DOT 0x0008 +#define HAS_DOT_DOT 0x0010 +#define HAS_SPACE 0x0020 +#define HAS_INVALID 0x0040 +#define HAS_ASTERISK 0x0080 +#define HAS_UNDERSCORE 0x0100 +#define HAS_LONG_LABEL 0x0200 + +/****************************************************************************** + * DnsValidateName_W [DNSAPI.@] + * + */ +DNS_STATUS WINAPI DnsValidateName_W( PCWSTR name, DNS_NAME_FORMAT format ) +{ + PCWSTR p; + unsigned int i, j, state = 0; + static const WCHAR invalid[] = { + '{','|','}','~','[','\\',']','^','\'',':',';','<','=','>', + '?','@','!','\"','#','$','%','^','`','(',')','+','/',',',0 }; + + if (!name) return ERROR_INVALID_NAME; + + for (p = name, i = 0, j = 0; *p; p++, i++, j++) + { + if (*p == '.') + { + j = 0; + state |= HAS_DOT; + if (p[1] == '.') state |= HAS_DOT_DOT; + } + else if (*p < '0' || *p > '9') state |= HAS_NON_NUMERIC; + else state |= HAS_NUMERIC; + + if (j > 62) state |= HAS_LONG_LABEL; + + if (wcschr( invalid, *p )) state |= HAS_INVALID; + else if ((unsigned)*p > 127) state |= HAS_EXTENDED; + else if (*p == ' ') state |= HAS_SPACE; + else if (*p == '_') state |= HAS_UNDERSCORE; + else if (*p == '*') state |= HAS_ASTERISK; + } + + if (i == 0 || i > 255 || + (state & HAS_LONG_LABEL) || + (state & HAS_DOT_DOT) || + (name[0] == '.' && name[1])) return ERROR_INVALID_NAME; + + switch (format) + { + case DnsNameDomain: + { + if (!(state & HAS_NON_NUMERIC) && (state & HAS_NUMERIC)) + return DNS_ERROR_NUMERIC_NAME; + if ((state & HAS_EXTENDED) || (state & HAS_UNDERSCORE)) + return DNS_ERROR_NON_RFC_NAME; + if ((state & HAS_SPACE) || + (state & HAS_INVALID) || + (state & HAS_ASTERISK)) return DNS_ERROR_INVALID_NAME_CHAR; + break; + } + case DnsNameDomainLabel: + { + if (state & HAS_DOT) return ERROR_INVALID_NAME; + if ((state & HAS_EXTENDED) || (state & HAS_UNDERSCORE)) + return DNS_ERROR_NON_RFC_NAME; + if ((state & HAS_SPACE) || + (state & HAS_INVALID) || + (state & HAS_ASTERISK)) return DNS_ERROR_INVALID_NAME_CHAR; + break; + } + case DnsNameHostnameFull: + { + if (!(state & HAS_NON_NUMERIC) && (state & HAS_NUMERIC)) + return DNS_ERROR_NUMERIC_NAME; + if ((state & HAS_EXTENDED) || (state & HAS_UNDERSCORE)) + return DNS_ERROR_NON_RFC_NAME; + if ((state & HAS_SPACE) || + (state & HAS_INVALID) || + (state & HAS_ASTERISK)) return DNS_ERROR_INVALID_NAME_CHAR; + break; + } + case DnsNameHostnameLabel: + { + if (state & HAS_DOT) return ERROR_INVALID_NAME; + if (!(state & HAS_NON_NUMERIC) && (state & HAS_NUMERIC)) + return DNS_ERROR_NUMERIC_NAME; + if ((state & HAS_EXTENDED) || (state & HAS_UNDERSCORE)) + return DNS_ERROR_NON_RFC_NAME; + if ((state & HAS_SPACE) || + (state & HAS_INVALID) || + (state & HAS_ASTERISK)) return DNS_ERROR_INVALID_NAME_CHAR; + break; + } + case DnsNameWildcard: + { + if (!(state & HAS_NON_NUMERIC) && (state & HAS_NUMERIC)) return ERROR_INVALID_NAME; - - CurrentLabel = NextLabel; - } while(*CurrentLabel); - - CurrentChar = Name; - - while(*CurrentChar) - { - if(wcschr(L" {|}~[\\]^':;<=>?@!\"#$%^`()+/,",*CurrentChar)) + if (name[0] != '*') return ERROR_INVALID_NAME; + if (name[1] && name[1] != '.') return DNS_ERROR_INVALID_NAME_CHAR; - - CurrentChar++; - } - - if((!AllowLeadingAst && Name[0] == '*') || (AllowLeadingAst && Name[0] == '*' && Name[1] && Name[1] != '.')) - return DNS_ERROR_INVALID_NAME_CHAR; - - if(wcschr(Name + 1, '*')) - return DNS_ERROR_INVALID_NAME_CHAR; - - CurrentChar = Name; - - while(!AllowAllDigits && *CurrentChar) - { - if(*CurrentChar == '.' || (*CurrentChar >= '0' && *CurrentChar <= '9')) - return DNS_ERROR_NUMERIC_NAME; - } - - if(((AllowLeadingUnderscore && Name[0] == '_') || Name[0] != '_') && !DnsIntContainsUnderscore(Name + 1)) - return DNS_ERROR_NON_RFC_NAME; - + if ((state & HAS_EXTENDED) || + (state & HAS_SPACE) || + (state & HAS_INVALID)) return ERROR_INVALID_NAME; + break; + } + case DnsNameSrvRecord: + { + if (!(state & HAS_NON_NUMERIC) && (state & HAS_NUMERIC)) + return ERROR_INVALID_NAME; + if (name[0] != '_') return ERROR_INVALID_NAME; + if ((state & HAS_UNDERSCORE) && !name[1]) + return DNS_ERROR_NON_RFC_NAME; + if ((state & HAS_EXTENDED) || + (state & HAS_SPACE) || + (state & HAS_INVALID)) return ERROR_INVALID_NAME; + break; + } + default: + DPRINT1( "unknown format: %d\n", format ); + break; + } return ERROR_SUCCESS; } - -DNS_STATUS WINAPI -DnsValidateName_UTF8(LPCSTR Name, - DNS_NAME_FORMAT Format) -{ - PWCHAR Buffer; - int StrLenWc; - DNS_STATUS Status; - - StrLenWc = mbstowcs(NULL, Name, 0); - Buffer = RtlAllocateHeap(RtlGetProcessHeap(), 0, sizeof(WCHAR) * (StrLenWc + 1)); - mbstowcs(Buffer, Name, StrLenWc + 1); - Status = DnsValidateName_W(Buffer, Format); - RtlFreeHeap(RtlGetProcessHeap(), 0, Buffer); - - return Status; -} - -DNS_STATUS WINAPI -DnsValidateName_A(LPCSTR Name, - DNS_NAME_FORMAT Format) -{ - return DnsValidateName_UTF8(Name, Format); -} - -/* DnsNameCompare ********************** - * Return TRUE if the names are identical. - * - * Name1 & Name2 -- Names. - */ -BOOL WINAPI -DnsNameCompare_W(LPWSTR Name1, - LPWSTR Name2) -{ - int offset = 0; - - while(Name1[offset] && Name2[offset] && towupper(Name1[offset]) == towupper(Name2[offset])) - offset++; - - return - (!Name1[offset] && !Name2[offset]) || - (!Name1[offset] && !wcscmp(Name2 + offset, L".")) || - (!Name2[offset] && !wcscmp(Name1 + offset, L".")); -} - -BOOL WINAPI -DnsNameCompare_UTF8(LPCSTR Name1, - LPCSTR Name2) -{ - int offset = 0; - - while(Name1[offset] && Name2[offset] && toupper(Name1[offset]) == toupper(Name2[offset])) - offset++; - - return - (!Name1[offset] && !Name2[offset]) || - (!Name1[offset] && !strcmp(Name2 + offset, ".")) || - (!Name2[offset] && !strcmp(Name1 + offset, ".")); -} - -BOOL WINAPI -DnsNameCompare_A(LPSTR Name1, - LPSTR Name2) -{ - return DnsNameCompare_UTF8(Name1, Name2); -} Modified: trunk/reactos/dll/win32/dnsapi/dnsapi/precomp.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/dnsapi/dnsapi/pr…
============================================================================== --- trunk/reactos/dll/win32/dnsapi/dnsapi/precomp.h [iso-8859-1] (original) +++ trunk/reactos/dll/win32/dnsapi/dnsapi/precomp.h [iso-8859-1] Fri Jul 9 20:56:12 2010 @@ -20,3 +20,106 @@ /* Internal DNSAPI Headers */ #include <internal/windns.h> +static inline LPWSTR dns_strdup_uw( const char *str ) +{ + LPWSTR ret = NULL; + if (str) + { + DWORD len = MultiByteToWideChar( CP_UTF8, 0, str, -1, NULL, 0 ); + if ((ret = HeapAlloc(GetProcessHeap(),0,( len * sizeof(WCHAR) )))) + MultiByteToWideChar( CP_UTF8, 0, str, -1, ret, len ); + } + return ret; +} + +static inline LPWSTR dns_strdup_aw( LPCSTR str ) +{ + LPWSTR ret = NULL; + if (str) + { + DWORD len = MultiByteToWideChar( CP_ACP, 0, str, -1, NULL, 0 ); + if ((ret = HeapAlloc(GetProcessHeap(), 0, ( len * sizeof(WCHAR) )))) + MultiByteToWideChar( CP_ACP, 0, str, -1, ret, len ); + } + return ret; +} + +static inline LPSTR dns_strdup_a( LPCSTR src ) +{ + LPSTR dst; + + if (!src) return NULL; + dst = HeapAlloc(GetProcessHeap(), 0, (lstrlenA( src ) + 1) * sizeof(char) ); + if (dst) lstrcpyA( dst, src ); + return dst; +} + +static inline char *dns_strdup_u( const char *src ) +{ + char *dst; + + if (!src) return NULL; + dst = HeapAlloc(GetProcessHeap(), 0, (strlen( src ) + 1) * sizeof(char) ); + if (dst) strcpy( dst, src ); + return dst; +} + +static inline LPWSTR dns_strdup_w( LPCWSTR src ) +{ + LPWSTR dst; + + if (!src) return NULL; + dst = HeapAlloc(GetProcessHeap(), 0, (lstrlenW( src ) + 1) * sizeof(WCHAR) ); + if (dst) lstrcpyW( dst, src ); + return dst; +} + +static inline LPSTR dns_strdup_wa( LPCWSTR str ) +{ + LPSTR ret = NULL; + if (str) + { + DWORD len = WideCharToMultiByte( CP_ACP, 0, str, -1, NULL, 0, NULL, NULL ); + if ((ret = HeapAlloc(GetProcessHeap(), 0, len ))) + WideCharToMultiByte( CP_ACP, 0, str, -1, ret, len, NULL, NULL ); + } + return ret; +} + +static inline char *dns_strdup_wu( LPCWSTR str ) +{ + LPSTR ret = NULL; + if (str) + { + DWORD len = WideCharToMultiByte( CP_UTF8, 0, str, -1, NULL, 0, NULL, NULL ); + if ((ret = HeapAlloc(GetProcessHeap(), 0, len ))) + WideCharToMultiByte( CP_UTF8, 0, str, -1, ret, len, NULL, NULL ); + } + return ret; +} + +static inline char *dns_strdup_au( LPCSTR src ) +{ + char *dst = NULL; + LPWSTR ret = dns_strdup_aw( src ); + + if (ret) + { + dst = dns_strdup_wu( ret ); + HeapFree( GetProcessHeap(), 0, ret ); + } + return dst; +} + +static inline LPSTR dns_strdup_ua( const char *src ) +{ + LPSTR dst = NULL; + LPWSTR ret = dns_strdup_uw( src ); + + if (ret) + { + dst = dns_strdup_wa( ret ); + HeapFree( GetProcessHeap(), 0, ret ); + } + return dst; +} Modified: trunk/reactos/dll/win32/dnsapi/dnsapi/stubs.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/dnsapi/dnsapi/st…
============================================================================== --- trunk/reactos/dll/win32/dnsapi/dnsapi/stubs.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/dnsapi/dnsapi/stubs.c [iso-8859-1] Fri Jul 9 20:56:12 2010 @@ -561,49 +561,6 @@ { UNIMPLEMENTED; return ERROR_OUTOFMEMORY; -} - -BOOL WINAPI -DnsRecordCompare(PDNS_RECORD pRecord1, - PDNS_RECORD pRecord2) -{ - UNIMPLEMENTED; - return ERROR_OUTOFMEMORY; -} - -PDNS_RECORD WINAPI -DnsRecordCopyEx(PDNS_RECORD pRecord, - DNS_CHARSET CharSetIn, - DNS_CHARSET CharSetOut) -{ - UNIMPLEMENTED; - return NULL; -} - -BOOL WINAPI -DnsRecordSetCompare(PDNS_RECORD pRR1, - PDNS_RECORD pRR2, - PDNS_RECORD* ppDiff1, - PDNS_RECORD* ppDiff2) -{ - UNIMPLEMENTED; - return FALSE; -} - -PDNS_RECORD WINAPI -DnsRecordSetCopyEx(PDNS_RECORD pRecordSet, - DNS_CHARSET CharSetIn, - DNS_CHARSET CharSetOut) -{ - UNIMPLEMENTED; - return NULL; -} - -PDNS_RECORD WINAPI -DnsRecordSetDetach(PDNS_RECORD pRR) -{ - UNIMPLEMENTED; - return NULL; } DNS_STATUS WINAPI Modified: trunk/reactos/include/psdk/windns.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/windns.h?rev=…
============================================================================== --- trunk/reactos/include/psdk/windns.h [iso-8859-1] (original) +++ trunk/reactos/include/psdk/windns.h [iso-8859-1] Fri Jul 9 20:56:12 2010 @@ -34,62 +34,67 @@ #ifndef RC_INVOKE typedef DWORD IP4_ADDRESS; typedef DWORD DNS_STATUS; -enum { - DNS_TYPE_A=1, - DNS_TYPE_NS, - DNS_TYPE_MD, - DNS_TYPE_MF, - DNS_TYPE_CNAME, - DNS_TYPE_SOA, - DNS_TYPE_MB, - DNS_TYPE_MG, - DNS_TYPE_MR, - DNS_TYPE_NULL, - DNS_TYPE_WKS, - DNS_TYPE_PTR, - DNS_TYPE_HINFO, - DNS_TYPE_MINFO, - DNS_TYPE_MX, - DNS_TYPE_TEXT, - DNS_TYPE_RP, - DNS_TYPE_AFSDB, - DNS_TYPE_X25, - DNS_TYPE_ISDN, - DNS_TYPE_RT, - DNS_TYPE_NSAP, - DNS_TYPE_NSAPPTR, - DNS_TYPE_SIG, - DNS_TYPE_KEY, - DNS_TYPE_PX, - DNS_TYPE_GPOS, - DNS_TYPE_AAAA, - DNS_TYPE_LOC, - DNS_TYPE_NXT, - DNS_TYPE_EID, - DNS_TYPE_NIMLOC, - DNS_TYPE_SRV, - DNS_TYPE_ATMA, - DNS_TYPE_NAPTR, - DNS_TYPE_KX, - DNS_TYPE_CERT, - DNS_TYPE_A6, - DNS_TYPE_DNAME, - DNS_TYPE_SINK, - DNS_TYPE_OPT, - DNS_TYPE_UINFO=100, - DNS_TYPE_UID, - DNS_TYPE_GID, - DNS_TYPE_UNSPEC, - DNS_TYPE_ADDRS=248, - DNS_TYPE_TKEY, - DNS_TYPE_TSIG, - DNS_TYPE_IXFR, - DNS_TYPE_AXFR, - DNS_TYPE_MAILB, - DNS_TYPE_MAILA, - DNS_TYPE_ALL, - DNS_TYPE_ANY=DNS_TYPE_ALL -}; +#define DNS_TYPE_ZERO 0x0000 + +#define DNS_TYPE_A 0x0001 +#define DNS_TYPE_NS 0x0002 +#define DNS_TYPE_MD 0x0003 +#define DNS_TYPE_MF 0x0004 +#define DNS_TYPE_CNAME 0x0005 +#define DNS_TYPE_SOA 0x0006 +#define DNS_TYPE_MB 0x0007 +#define DNS_TYPE_MG 0x0008 +#define DNS_TYPE_MR 0x0009 +#define DNS_TYPE_NULL 0x000a +#define DNS_TYPE_WKS 0x000b +#define DNS_TYPE_PTR 0x000c +#define DNS_TYPE_HINFO 0x000d +#define DNS_TYPE_MINFO 0x000e +#define DNS_TYPE_MX 0x000f +#define DNS_TYPE_TEXT 0x0010 +#define DNS_TYPE_RP 0x0011 +#define DNS_TYPE_AFSDB 0x0012 +#define DNS_TYPE_X25 0x0013 +#define DNS_TYPE_ISDN 0x0014 +#define DNS_TYPE_RT 0x0015 +#define DNS_TYPE_NSAP 0x0016 +#define DNS_TYPE_NSAPPTR 0x0017 +#define DNS_TYPE_SIG 0x0018 +#define DNS_TYPE_KEY 0x0019 +#define DNS_TYPE_PX 0x001a +#define DNS_TYPE_GPOS 0x001b +#define DNS_TYPE_AAAA 0x001c +#define DNS_TYPE_LOC 0x001d +#define DNS_TYPE_NXT 0x001e +#define DNS_TYPE_EID 0x001f +#define DNS_TYPE_NIMLOC 0x0020 +#define DNS_TYPE_SRV 0x0021 +#define DNS_TYPE_ATMA 0x0022 +#define DNS_TYPE_NAPTR 0x0023 +#define DNS_TYPE_KX 0x0024 +#define DNS_TYPE_CERT 0x0025 +#define DNS_TYPE_A6 0x0026 +#define DNS_TYPE_DNAME 0x0027 +#define DNS_TYPE_SINK 0x0028 +#define DNS_TYPE_OPT 0x0029 +#define DNS_TYPE_UINFO 0x0064 +#define DNS_TYPE_UID 0x0065 +#define DNS_TYPE_GID 0x0066 +#define DNS_TYPE_UNSPEC 0x0067 +#define DNS_TYPE_ADDRS 0x00f8 +#define DNS_TYPE_TKEY 0x00f9 +#define DNS_TYPE_TSIG 0x00fa +#define DNS_TYPE_IXFR 0x00fb +#define DNS_TYPE_AXFR 0x00fc +#define DNS_TYPE_MAILB 0x00fd +#define DNS_TYPE_MAILA 0x00fe +#define DNS_TYPE_ALL 0x00ff +#define DNS_TYPE_ANY 0x00ff + +#define DNS_TYPE_WINS 0xff01 +#define DNS_TYPE_WINSR 0xff02 +#define DNS_TYPE_NBSTAT (DNS_TYPE_WINSR) + typedef enum _DNS_CHARSET { DnsCharSetUnknown, @@ -503,8 +508,8 @@ DNS_STATUS WINAPI DnsModifyRecordsInSet_A(PDNS_RECORD,PDNS_RECORD,DWORD,HANDLE,PIP4_ARRAY,PVOID); DNS_STATUS WINAPI DnsModifyRecordsInSet_W(PDNS_RECORD,PDNS_RECORD,DWORD,HANDLE,PIP4_ARRAY,PVOID); DNS_STATUS WINAPI DnsModifyRecordsInSet_UTF8(PDNS_RECORD,PDNS_RECORD,DWORD,HANDLE,PIP4_ARRAY,PVOID); -BOOL WINAPI DnsNameCompare_A(LPSTR,LPSTR); -BOOL WINAPI DnsNameCompare_W(LPWSTR,LPWSTR); +BOOL WINAPI DnsNameCompare_A(PCSTR,PCSTR); +BOOL WINAPI DnsNameCompare_W(PCWSTR,PCWSTR); DNS_STATUS WINAPI DnsQuery_A(PCSTR,WORD,DWORD,PIP4_ARRAY,PDNS_RECORD*,PVOID*); DNS_STATUS WINAPI DnsQuery_W(PCWSTR,WORD,DWORD,PIP4_ARRAY,PDNS_RECORD*,PVOID*); DNS_STATUS WINAPI DnsQuery_UTF8(PCSTR,WORD,DWORD,PIP4_ARRAY,PDNS_RECORD*,PVOID*);
14 years, 5 months
1
0
0
0
[pschweitzer] 47981: [FASTFAT] Check PathName length before accessing it. This fixes ntdll_winetest file test BSOD. But the test crashes a bit farther.
by pschweitzer@svn.reactos.org
Author: pschweitzer Date: Fri Jul 9 19:39:55 2010 New Revision: 47981 URL:
http://svn.reactos.org/svn/reactos?rev=47981&view=rev
Log: [FASTFAT] Check PathName length before accessing it. This fixes ntdll_winetest file test BSOD. But the test crashes a bit farther. Modified: trunk/reactos/drivers/filesystems/fastfat/create.c Modified: trunk/reactos/drivers/filesystems/fastfat/create.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filesystems/fastfa…
============================================================================== --- trunk/reactos/drivers/filesystems/fastfat/create.c [iso-8859-1] (original) +++ trunk/reactos/drivers/filesystems/fastfat/create.c [iso-8859-1] Fri Jul 9 19:39:55 2010 @@ -522,7 +522,7 @@ return(STATUS_OBJECT_NAME_INVALID); } } - if (FileObject->RelatedFileObject && PathNameU.Buffer[0] == L'\\') + if (FileObject->RelatedFileObject && PathNameU.Length > sizeof(WCHAR) && PathNameU.Buffer[0] == L'\\') { return(STATUS_OBJECT_NAME_INVALID); }
14 years, 5 months
1
0
0
0
[gadamopoulos] 47980: [win32k] - Sync implementaion of dib, brushes, pens, palettes, xform, xlate and mouse pointer functions with trunk
by gadamopoulos@svn.reactos.org
Author: gadamopoulos Date: Fri Jul 9 16:13:10 2010 New Revision: 47980 URL:
http://svn.reactos.org/svn/reactos?rev=47980&view=rev
Log: [win32k] - Sync implementaion of dib, brushes, pens, palettes, xform, xlate and mouse pointer functions with trunk Added: branches/arwinss/reactos/subsystems/win32/win32k/dib/dib.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/dib.c branches/arwinss/reactos/subsystems/win32/win32k/dib/dib16bpp.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/dib16bpp.c branches/arwinss/reactos/subsystems/win32/win32k/dib/dib1bpp.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/dib1bpp.c branches/arwinss/reactos/subsystems/win32/win32k/dib/dib24bpp.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/dib24bpp.c branches/arwinss/reactos/subsystems/win32/win32k/dib/dib24bppc.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/dib24bppc.c branches/arwinss/reactos/subsystems/win32/win32k/dib/dib32bpp.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/dib32bpp.c branches/arwinss/reactos/subsystems/win32/win32k/dib/dib32bppc.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/dib32bppc.c branches/arwinss/reactos/subsystems/win32/win32k/dib/dib4bpp.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/dib4bpp.c branches/arwinss/reactos/subsystems/win32/win32k/dib/dib8bpp.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/dib8bpp.c branches/arwinss/reactos/subsystems/win32/win32k/dib/floodfill.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/floodfill.c branches/arwinss/reactos/subsystems/win32/win32k/dib/i386/dib24bpp_hline.s - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/i386/dib24bpp_hline.s branches/arwinss/reactos/subsystems/win32/win32k/dib/i386/dib32bpp_colorfill.s - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/i386/dib32bpp_colorfill.s branches/arwinss/reactos/subsystems/win32/win32k/dib/i386/dib32bpp_hline.s - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/i386/dib32bpp_hline.s branches/arwinss/reactos/subsystems/win32/win32k/dib/stretchblt.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/dib/stretchblt.c branches/arwinss/reactos/subsystems/win32/win32k/eng/engbrush.c - copied, changed from r47905, trunk/reactos/subsystems/win32/win32k/eng/engbrush.c branches/arwinss/reactos/subsystems/win32/win32k/eng/engpal.c - copied, changed from r47905, trunk/reactos/subsystems/win32/win32k/objects/palette.c branches/arwinss/reactos/subsystems/win32/win32k/eng/engpointer.c - copied, changed from r47905, trunk/reactos/subsystems/win32/win32k/eng/mouse.c branches/arwinss/reactos/subsystems/win32/win32k/eng/engxform.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/objects/xformobj.c branches/arwinss/reactos/subsystems/win32/win32k/eng/engxlate.c - copied, changed from r47905, trunk/reactos/subsystems/win32/win32k/eng/xlate.c branches/arwinss/reactos/subsystems/win32/win32k/gre/brushobj.c - copied, changed from r47905, trunk/reactos/subsystems/win32/win32k/objects/brush.c branches/arwinss/reactos/subsystems/win32/win32k/gre/gdidbg.c - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/objects/gdidbg.c branches/arwinss/reactos/subsystems/win32/win32k/gre/pen.c - copied, changed from r47905, trunk/reactos/subsystems/win32/win32k/objects/pen.c branches/arwinss/reactos/subsystems/win32/win32k/include/brush.h - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/include/brush.h branches/arwinss/reactos/subsystems/win32/win32k/include/color.h - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/include/color.h branches/arwinss/reactos/subsystems/win32/win32k/include/dib.h - copied, changed from r47905, trunk/reactos/subsystems/win32/win32k/dib/dib.h branches/arwinss/reactos/subsystems/win32/win32k/include/palobj.h - copied unchanged from r47905, trunk/reactos/subsystems/win32/win32k/include/palette.h branches/arwinss/reactos/subsystems/win32/win32k/include/pen.h - copied, changed from r47905, trunk/reactos/subsystems/win32/win32k/include/pen.h branches/arwinss/reactos/subsystems/win32/win32k/include/xlateobj.h - copied, changed from r47905, trunk/reactos/subsystems/win32/win32k/include/xlateobj.h Removed: branches/arwinss/reactos/subsystems/win32/win32k/dib/dibXXbpp.c branches/arwinss/reactos/subsystems/win32/win32k/eng/engpoint.c branches/arwinss/reactos/subsystems/win32/win32k/gre/cursoricon.c branches/arwinss/reactos/subsystems/win32/win32k/gre/palobj.c branches/arwinss/reactos/subsystems/win32/win32k/gre/xformobj.c branches/arwinss/reactos/subsystems/win32/win32k/gre/xlateobj.c branches/arwinss/reactos/subsystems/win32/win32k/include/brushobj.h Modified: branches/arwinss/reactos/subsystems/win32/win32k/eng/device.c branches/arwinss/reactos/subsystems/win32/win32k/eng/engblt.c branches/arwinss/reactos/subsystems/win32/win32k/eng/engsurf.c branches/arwinss/reactos/subsystems/win32/win32k/gdi/bitmap.c branches/arwinss/reactos/subsystems/win32/win32k/gdi/dc.c branches/arwinss/reactos/subsystems/win32/win32k/gdi/enum.c branches/arwinss/reactos/subsystems/win32/win32k/gdi/misc.c branches/arwinss/reactos/subsystems/win32/win32k/gre/arc.c branches/arwinss/reactos/subsystems/win32/win32k/gre/bitblt.c branches/arwinss/reactos/subsystems/win32/win32k/gre/drawing.c branches/arwinss/reactos/subsystems/win32/win32k/gre/ellipse.c branches/arwinss/reactos/subsystems/win32/win32k/gre/font.c branches/arwinss/reactos/subsystems/win32/win32k/gre/gdiobj.c branches/arwinss/reactos/subsystems/win32/win32k/gre/lineto.c branches/arwinss/reactos/subsystems/win32/win32k/gre/polyfill.c branches/arwinss/reactos/subsystems/win32/win32k/gre/rect.c branches/arwinss/reactos/subsystems/win32/win32k/gre/surfobj.c branches/arwinss/reactos/subsystems/win32/win32k/include/cursor.h branches/arwinss/reactos/subsystems/win32/win32k/include/dc.h branches/arwinss/reactos/subsystems/win32/win32k/include/devobj.h branches/arwinss/reactos/subsystems/win32/win32k/include/gdiobj.h branches/arwinss/reactos/subsystems/win32/win32k/include/gre.h branches/arwinss/reactos/subsystems/win32/win32k/include/surfobj.h branches/arwinss/reactos/subsystems/win32/win32k/include/swm.h branches/arwinss/reactos/subsystems/win32/win32k/include/tags.h branches/arwinss/reactos/subsystems/win32/win32k/include/win32kp.h branches/arwinss/reactos/subsystems/win32/win32k/include/xformobj.h branches/arwinss/reactos/subsystems/win32/win32k/main/cursor.c branches/arwinss/reactos/subsystems/win32/win32k/main/init.c branches/arwinss/reactos/subsystems/win32/win32k/main/monitor.c branches/arwinss/reactos/subsystems/win32/win32k/swm/winman.c branches/arwinss/reactos/subsystems/win32/win32k/win32k.rbuild [This mail would be too long, it was shortened to contain the URLs only.] Removed: branches/arwinss/reactos/subsystems/win32/win32k/dib/dibXXbpp.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/eng/device.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/eng/engblt.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Copied: branches/arwinss/reactos/subsystems/win32/win32k/eng/engbrush.c (from r47905, trunk/reactos/subsystems/win32/win32k/eng/engbrush.c) URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Copied: branches/arwinss/reactos/subsystems/win32/win32k/eng/engpal.c (from r47905, trunk/reactos/subsystems/win32/win32k/objects/palette.c) URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Removed: branches/arwinss/reactos/subsystems/win32/win32k/eng/engpoint.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Copied: branches/arwinss/reactos/subsystems/win32/win32k/eng/engpointer.c (from r47905, trunk/reactos/subsystems/win32/win32k/eng/mouse.c) URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/eng/engsurf.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Copied: branches/arwinss/reactos/subsystems/win32/win32k/eng/engxlate.c (from r47905, trunk/reactos/subsystems/win32/win32k/eng/xlate.c) URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gdi/bitmap.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gdi/dc.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gdi/enum.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gdi/misc.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gre/arc.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gre/bitblt.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Copied: branches/arwinss/reactos/subsystems/win32/win32k/gre/brushobj.c (from r47905, trunk/reactos/subsystems/win32/win32k/objects/brush.c) URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Removed: branches/arwinss/reactos/subsystems/win32/win32k/gre/cursoricon.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gre/drawing.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gre/ellipse.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gre/font.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gre/gdiobj.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gre/lineto.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Removed: branches/arwinss/reactos/subsystems/win32/win32k/gre/palobj.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Copied: branches/arwinss/reactos/subsystems/win32/win32k/gre/pen.c (from r47905, trunk/reactos/subsystems/win32/win32k/objects/pen.c) URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gre/polyfill.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gre/rect.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/gre/surfobj.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Removed: branches/arwinss/reactos/subsystems/win32/win32k/gre/xformobj.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Removed: branches/arwinss/reactos/subsystems/win32/win32k/gre/xlateobj.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Removed: branches/arwinss/reactos/subsystems/win32/win32k/include/brushobj.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/include/cursor.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/include/dc.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/include/devobj.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Copied: branches/arwinss/reactos/subsystems/win32/win32k/include/dib.h (from r47905, trunk/reactos/subsystems/win32/win32k/dib/dib.h) URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/include/gdiobj.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/include/gre.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Copied: branches/arwinss/reactos/subsystems/win32/win32k/include/pen.h (from r47905, trunk/reactos/subsystems/win32/win32k/include/pen.h) URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/include/surfobj.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/include/swm.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/include/tags.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/include/win32kp.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/include/xformobj.h URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Copied: branches/arwinss/reactos/subsystems/win32/win32k/include/xlateobj.h (from r47905, trunk/reactos/subsystems/win32/win32k/include/xlateobj.h) URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/main/cursor.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/main/init.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/main/monitor.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/swm/winman.c URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
Modified: branches/arwinss/reactos/subsystems/win32/win32k/win32k.rbuild URL:
http://svn.reactos.org/svn/reactos/branches/arwinss/reactos/subsystems/win3…
14 years, 5 months
1
0
0
0
[akhaldi] 47979: [DDK] - Remove ntddscsi.h [PSDK] - Import ntddscsi.h from mingw-w64.
by akhaldi@svn.reactos.org
Author: akhaldi Date: Fri Jul 9 14:39:28 2010 New Revision: 47979 URL:
http://svn.reactos.org/svn/reactos?rev=47979&view=rev
Log: [DDK] - Remove ntddscsi.h [PSDK] - Import ntddscsi.h from mingw-w64. Added: trunk/reactos/include/psdk/ntddscsi.h (with props) Removed: trunk/reactos/include/ddk/ntddscsi.h Removed: trunk/reactos/include/ddk/ntddscsi.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ddk/ntddscsi.h?rev…
============================================================================== --- trunk/reactos/include/ddk/ntddscsi.h [iso-8859-1] (original) +++ trunk/reactos/include/ddk/ntddscsi.h (removed) @@ -1,171 +1,0 @@ -/* - * ntddscsi.h - * - * SCSI port IOCTL interface. - * - * This file is part of the w32api package. - * - * Contributors: - * Created by Casper S. Hornstrup <chorns(a)users.sourceforge.net> - * - * 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 - * DISCLAIMED. This includes but is not limited to warranties of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. - * - */ - -#ifndef __NTDDSCSI_H -#define __NTDDSCSI_H - -#ifdef __cplusplus -extern "C" { -#endif - -#define DD_SCSI_DEVICE_NAME "\\Device\\ScsiPort" -#define DD_SCSI_DEVICE_NAME_U L"\\Device\\ScsiPort" - -#define IOCTL_SCSI_BASE FILE_DEVICE_CONTROLLER - -#define IOCTL_SCSI_FREE_DUMP_POINTERS \ - CTL_CODE(IOCTL_SCSI_BASE, 0x0409, METHOD_BUFFERED, FILE_ANY_ACCESS) - -#define IOCTL_SCSI_GET_INQUIRY_DATA \ - CTL_CODE(IOCTL_SCSI_BASE, 0x0403, METHOD_BUFFERED, FILE_ANY_ACCESS) - -#define IOCTL_SCSI_GET_CAPABILITIES \ - CTL_CODE(IOCTL_SCSI_BASE, 0x0404, METHOD_BUFFERED, FILE_ANY_ACCESS) - -#define IOCTL_SCSI_GET_ADDRESS \ - CTL_CODE(IOCTL_SCSI_BASE, 0x0406, METHOD_BUFFERED, FILE_ANY_ACCESS) - -#define IOCTL_SCSI_GET_DUMP_POINTERS \ - CTL_CODE(IOCTL_SCSI_BASE, 0x0408, METHOD_BUFFERED, FILE_ANY_ACCESS) - -#define IOCTL_SCSI_MINIPORT \ - CTL_CODE(IOCTL_SCSI_BASE, 0x0402, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS) - -#define IOCTL_SCSI_PASS_THROUGH \ - CTL_CODE(IOCTL_SCSI_BASE, 0x0401, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS) - -#define IOCTL_SCSI_PASS_THROUGH_DIRECT \ - CTL_CODE(IOCTL_SCSI_BASE, 0x0405, METHOD_BUFFERED, FILE_READ_ACCESS | FILE_WRITE_ACCESS) - -#define IOCTL_SCSI_RESCAN_BUS \ - CTL_CODE(IOCTL_SCSI_BASE, 0x0407, METHOD_BUFFERED, FILE_ANY_ACCESS) - - -DEFINE_GUID(ScsiRawInterfaceGuid, \ - 0x53f56309L, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b); - -DEFINE_GUID(WmiScsiAddressGuid, \ - 0x53f5630fL, 0xb6bf, 0x11d0, 0x94, 0xf2, 0x00, 0xa0, 0xc9, 0x1e, 0xfb, 0x8b); - -typedef struct _SCSI_PASS_THROUGH { - USHORT Length; - UCHAR ScsiStatus; - UCHAR PathId; - UCHAR TargetId; - UCHAR Lun; - UCHAR CdbLength; - UCHAR SenseInfoLength; - UCHAR DataIn; - ULONG DataTransferLength; - ULONG TimeOutValue; - ULONG_PTR DataBufferOffset; - ULONG SenseInfoOffset; - UCHAR Cdb[16]; -} SCSI_PASS_THROUGH, *PSCSI_PASS_THROUGH; - -typedef struct _SCSI_PASS_THROUGH_DIRECT { - USHORT Length; - UCHAR ScsiStatus; - UCHAR PathId; - UCHAR TargetId; - UCHAR Lun; - UCHAR CdbLength; - UCHAR SenseInfoLength; - UCHAR DataIn; - ULONG DataTransferLength; - ULONG TimeOutValue; - PVOID DataBuffer; - ULONG SenseInfoOffset; - UCHAR Cdb[16]; -} SCSI_PASS_THROUGH_DIRECT, *PSCSI_PASS_THROUGH_DIRECT; - -typedef struct _SRB_IO_CONTROL { - ULONG HeaderLength; - UCHAR Signature[8]; - ULONG Timeout; - ULONG ControlCode; - ULONG ReturnCode; - ULONG Length; -} SRB_IO_CONTROL, *PSRB_IO_CONTROL; - -typedef struct _SCSI_ADDRESS { - ULONG Length; - UCHAR PortNumber; - UCHAR PathId; - UCHAR TargetId; - UCHAR Lun; -} SCSI_ADDRESS, *PSCSI_ADDRESS; - -typedef struct _SCSI_BUS_DATA { - UCHAR NumberOfLogicalUnits; - UCHAR InitiatorBusId; - ULONG InquiryDataOffset; -}SCSI_BUS_DATA, *PSCSI_BUS_DATA; - -typedef struct _SCSI_ADAPTER_BUS_INFO { - UCHAR NumberOfBuses; - SCSI_BUS_DATA BusData[1]; -} SCSI_ADAPTER_BUS_INFO, *PSCSI_ADAPTER_BUS_INFO; - -typedef struct _IO_SCSI_CAPABILITIES { - ULONG Length; - ULONG MaximumTransferLength; - ULONG MaximumPhysicalPages; - ULONG SupportedAsynchronousEvents; - ULONG AlignmentMask; - BOOLEAN TaggedQueuing; - BOOLEAN AdapterScansDown; - BOOLEAN AdapterUsesPio; -} IO_SCSI_CAPABILITIES, *PIO_SCSI_CAPABILITIES; - -typedef struct _SCSI_INQUIRY_DATA { - UCHAR PathId; - UCHAR TargetId; - UCHAR Lun; - BOOLEAN DeviceClaimed; - ULONG InquiryDataLength; - ULONG NextInquiryDataOffset; - UCHAR InquiryData[1]; -} SCSI_INQUIRY_DATA, *PSCSI_INQUIRY_DATA; - -#define SCSI_IOCTL_DATA_OUT 0 -#define SCSI_IOCTL_DATA_IN 1 -#define SCSI_IOCTL_DATA_UNSPECIFIED 2 - -typedef struct _DUMP_POINTERS { - struct _ADAPTER_OBJECT *AdapterObject; - PVOID MappedRegisterBase; - PVOID DumpData; - PVOID CommonBufferVa; - LARGE_INTEGER CommonBufferPa; - ULONG CommonBufferSize; - BOOLEAN AllocateCommonBuffers; - BOOLEAN UseDiskDump; - UCHAR Spare1[2]; - PVOID DeviceObject; -} DUMP_POINTERS, *PDUMP_POINTERS; - -#ifdef __cplusplus -} -#endif - -#endif /* __NTDDSCSI_H */ Added: trunk/reactos/include/psdk/ntddscsi.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/ntddscsi.h?re…
============================================================================== --- trunk/reactos/include/psdk/ntddscsi.h (added) +++ trunk/reactos/include/psdk/ntddscsi.h [iso-8859-1] Fri Jul 9 14:39:28 2010 @@ -1,0 +1,249 @@ +/** + * This file has no copyright assigned and is placed in the Public Domain. + * This file is part of the w64 mingw-runtime package. + * No warranty is given; refer to the file DISCLAIMER.PD within this package. + */ +#ifdef DEFINE_GUID + +#ifndef FAR +#define FAR +#endif + +DEFINE_GUID(ScsiRawInterfaceGuid,0x53f56309L,0xb6bf,0x11d0,0x94,0xf2,0x00,0xa0,0xc9,0x1e,0xfb,0x8b); +DEFINE_GUID(WmiScsiAddressGuid,0x53f5630fL,0xb6bf,0x11d0,0x94,0xf2,0x00,0xa0,0xc9,0x1e,0xfb,0x8b); +#endif /* DEFINE_GUID */ + +#ifndef _NTDDSCSIH_ +#define _NTDDSCSIH_ + +#ifdef __cplusplus +extern "C" { +#endif + +#define IOCTL_SCSI_BASE FILE_DEVICE_CONTROLLER + +#define DD_SCSI_DEVICE_NAME "\\Device\\ScsiPort" +#define DD_SCSI_DEVICE_NAME_U L"\\Device\\ScsiPort" + +#define IOCTL_SCSI_PASS_THROUGH CTL_CODE(IOCTL_SCSI_BASE,0x0401,METHOD_BUFFERED,FILE_READ_ACCESS | FILE_WRITE_ACCESS) +#define IOCTL_SCSI_MINIPORT CTL_CODE(IOCTL_SCSI_BASE,0x0402,METHOD_BUFFERED,FILE_READ_ACCESS | FILE_WRITE_ACCESS) +#define IOCTL_SCSI_GET_INQUIRY_DATA CTL_CODE(IOCTL_SCSI_BASE,0x0403,METHOD_BUFFERED,FILE_ANY_ACCESS) +#define IOCTL_SCSI_GET_CAPABILITIES CTL_CODE(IOCTL_SCSI_BASE,0x0404,METHOD_BUFFERED,FILE_ANY_ACCESS) +#define IOCTL_SCSI_PASS_THROUGH_DIRECT CTL_CODE(IOCTL_SCSI_BASE,0x0405,METHOD_BUFFERED,FILE_READ_ACCESS | FILE_WRITE_ACCESS) +#define IOCTL_SCSI_GET_ADDRESS CTL_CODE(IOCTL_SCSI_BASE,0x0406,METHOD_BUFFERED,FILE_ANY_ACCESS) +#define IOCTL_SCSI_RESCAN_BUS CTL_CODE(IOCTL_SCSI_BASE,0x0407,METHOD_BUFFERED,FILE_ANY_ACCESS) +#define IOCTL_SCSI_GET_DUMP_POINTERS CTL_CODE(IOCTL_SCSI_BASE,0x0408,METHOD_BUFFERED,FILE_ANY_ACCESS) +#define IOCTL_SCSI_FREE_DUMP_POINTERS CTL_CODE(IOCTL_SCSI_BASE,0x0409,METHOD_BUFFERED,FILE_ANY_ACCESS) +#define IOCTL_IDE_PASS_THROUGH CTL_CODE(IOCTL_SCSI_BASE,0x040a,METHOD_BUFFERED,FILE_READ_ACCESS | FILE_WRITE_ACCESS) +#define IOCTL_ATA_PASS_THROUGH CTL_CODE(IOCTL_SCSI_BASE,0x040b,METHOD_BUFFERED,FILE_READ_ACCESS | FILE_WRITE_ACCESS) +#define IOCTL_ATA_PASS_THROUGH_DIRECT CTL_CODE(IOCTL_SCSI_BASE,0x040c,METHOD_BUFFERED,FILE_READ_ACCESS | FILE_WRITE_ACCESS) + + typedef struct _SCSI_PASS_THROUGH { + USHORT Length; + UCHAR ScsiStatus; + UCHAR PathId; + UCHAR TargetId; + UCHAR Lun; + UCHAR CdbLength; + UCHAR SenseInfoLength; + UCHAR DataIn; + ULONG DataTransferLength; + ULONG TimeOutValue; + ULONG_PTR DataBufferOffset; + ULONG SenseInfoOffset; + UCHAR Cdb[16]; + }SCSI_PASS_THROUGH,*PSCSI_PASS_THROUGH; + + typedef struct _SCSI_PASS_THROUGH_DIRECT { + USHORT Length; + UCHAR ScsiStatus; + UCHAR PathId; + UCHAR TargetId; + UCHAR Lun; + UCHAR CdbLength; + UCHAR SenseInfoLength; + UCHAR DataIn; + ULONG DataTransferLength; + ULONG TimeOutValue; + PVOID DataBuffer; + ULONG SenseInfoOffset; + UCHAR Cdb[16]; + }SCSI_PASS_THROUGH_DIRECT,*PSCSI_PASS_THROUGH_DIRECT; + +#if defined(_WIN64) + typedef struct _SCSI_PASS_THROUGH32 { + USHORT Length; + UCHAR ScsiStatus; + UCHAR PathId; + UCHAR TargetId; + UCHAR Lun; + UCHAR CdbLength; + UCHAR SenseInfoLength; + UCHAR DataIn; + ULONG DataTransferLength; + ULONG TimeOutValue; + ULONG32 DataBufferOffset; + ULONG SenseInfoOffset; + UCHAR Cdb[16]; + } SCSI_PASS_THROUGH32,*PSCSI_PASS_THROUGH32; + + typedef struct _SCSI_PASS_THROUGH_DIRECT32 { + USHORT Length; + UCHAR ScsiStatus; + UCHAR PathId; + UCHAR TargetId; + UCHAR Lun; + UCHAR CdbLength; + UCHAR SenseInfoLength; + UCHAR DataIn; + ULONG DataTransferLength; + ULONG TimeOutValue; + VOID *DataBuffer; + ULONG SenseInfoOffset; + UCHAR Cdb[16]; + } SCSI_PASS_THROUGH_DIRECT32,*PSCSI_PASS_THROUGH_DIRECT32; +#endif /* _WIN64 */ + + typedef struct _ATA_PASS_THROUGH_EX { + USHORT Length; + USHORT AtaFlags; + UCHAR PathId; + UCHAR TargetId; + UCHAR Lun; + UCHAR ReservedAsUchar; + ULONG DataTransferLength; + ULONG TimeOutValue; + ULONG ReservedAsUlong; + ULONG_PTR DataBufferOffset; + UCHAR PreviousTaskFile[8]; + UCHAR CurrentTaskFile[8]; + } ATA_PASS_THROUGH_EX,*PATA_PASS_THROUGH_EX; + + typedef struct _ATA_PASS_THROUGH_DIRECT { + USHORT Length; + USHORT AtaFlags; + UCHAR PathId; + UCHAR TargetId; + UCHAR Lun; + UCHAR ReservedAsUchar; + ULONG DataTransferLength; + ULONG TimeOutValue; + ULONG ReservedAsUlong; + PVOID DataBuffer; + UCHAR PreviousTaskFile[8]; + UCHAR CurrentTaskFile[8]; + } ATA_PASS_THROUGH_DIRECT,*PATA_PASS_THROUGH_DIRECT; + +#if defined(_WIN64) + + typedef struct _ATA_PASS_THROUGH_EX32 { + USHORT Length; + USHORT AtaFlags; + UCHAR PathId; + UCHAR TargetId; + UCHAR Lun; + UCHAR ReservedAsUchar; + ULONG DataTransferLength; + ULONG TimeOutValue; + ULONG ReservedAsUlong; + ULONG32 DataBufferOffset; + UCHAR PreviousTaskFile[8]; + UCHAR CurrentTaskFile[8]; + } ATA_PASS_THROUGH_EX32,*PATA_PASS_THROUGH_EX32; + + typedef struct _ATA_PASS_THROUGH_DIRECT32 { + USHORT Length; + USHORT AtaFlags; + UCHAR PathId; + UCHAR TargetId; + UCHAR Lun; + UCHAR ReservedAsUchar; + ULONG DataTransferLength; + ULONG TimeOutValue; + ULONG ReservedAsUlong; + VOID *DataBuffer; + UCHAR PreviousTaskFile[8]; + UCHAR CurrentTaskFile[8]; + } ATA_PASS_THROUGH_DIRECT32,*PATA_PASS_THROUGH_DIRECT32; +#endif /* _WIN64 */ + +#define ATA_FLAGS_DRDY_REQUIRED (1 << 0) +#define ATA_FLAGS_DATA_IN (1 << 1) +#define ATA_FLAGS_DATA_OUT (1 << 2) +#define ATA_FLAGS_48BIT_COMMAND (1 << 3) +#define ATA_FLAGS_USE_DMA (1 << 4) + + typedef struct _SCSI_BUS_DATA { + UCHAR NumberOfLogicalUnits; + UCHAR InitiatorBusId; + ULONG InquiryDataOffset; + }SCSI_BUS_DATA,*PSCSI_BUS_DATA; + + typedef struct _SCSI_ADAPTER_BUS_INFO { + UCHAR NumberOfBuses; + SCSI_BUS_DATA BusData[1]; + } SCSI_ADAPTER_BUS_INFO,*PSCSI_ADAPTER_BUS_INFO; + + typedef struct _SCSI_INQUIRY_DATA { + UCHAR PathId; + UCHAR TargetId; + UCHAR Lun; + BOOLEAN DeviceClaimed; + ULONG InquiryDataLength; + ULONG NextInquiryDataOffset; + UCHAR InquiryData[1]; + }SCSI_INQUIRY_DATA,*PSCSI_INQUIRY_DATA; + + typedef struct _SRB_IO_CONTROL { + ULONG HeaderLength; + UCHAR Signature[8]; + ULONG Timeout; + ULONG ControlCode; + ULONG ReturnCode; + ULONG Length; + } SRB_IO_CONTROL,*PSRB_IO_CONTROL; + + typedef struct _IO_SCSI_CAPABILITIES { + ULONG Length; + ULONG MaximumTransferLength; + ULONG MaximumPhysicalPages; + ULONG SupportedAsynchronousEvents; + ULONG AlignmentMask; + BOOLEAN TaggedQueuing; + BOOLEAN AdapterScansDown; + BOOLEAN AdapterUsesPio; + } IO_SCSI_CAPABILITIES,*PIO_SCSI_CAPABILITIES; + + typedef struct _SCSI_ADDRESS { + ULONG Length; + UCHAR PortNumber; + UCHAR PathId; + UCHAR TargetId; + UCHAR Lun; + } SCSI_ADDRESS,*PSCSI_ADDRESS; + + struct _ADAPTER_OBJECT; + + typedef struct _DUMP_POINTERS { + struct _ADAPTER_OBJECT *AdapterObject; + PVOID MappedRegisterBase; + PVOID DumpData; + PVOID CommonBufferVa; + LARGE_INTEGER CommonBufferPa; + ULONG CommonBufferSize; + BOOLEAN AllocateCommonBuffers; + BOOLEAN UseDiskDump; + UCHAR Spare1[2]; + PVOID DeviceObject; + } DUMP_POINTERS,*PDUMP_POINTERS; + +#define SCSI_IOCTL_DATA_OUT 0 +#define SCSI_IOCTL_DATA_IN 1 +#define SCSI_IOCTL_DATA_UNSPECIFIED 2 + +#ifdef __cplusplus +} +#endif + +#endif /* _NTDDSCSIH_ */ + Propchange: trunk/reactos/include/psdk/ntddscsi.h ------------------------------------------------------------------------------ svn:eol-style = native
14 years, 5 months
1
0
0
0
[spetreolle] 47978: Sync __crtGetStringTypeW from Wine. Fixes msvcrt:locale crash.
by spetreolle@svn.reactos.org
Author: spetreolle Date: Fri Jul 9 14:33:03 2010 New Revision: 47978 URL:
http://svn.reactos.org/svn/reactos?rev=47978&view=rev
Log: Sync __crtGetStringTypeW from Wine. Fixes msvcrt:locale crash. Modified: trunk/reactos/dll/win32/msvcrt/msvcrt.spec trunk/reactos/lib/sdk/crt/locale/locale.c Modified: trunk/reactos/dll/win32/msvcrt/msvcrt.spec URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msvcrt/msvcrt.sp…
============================================================================== --- trunk/reactos/dll/win32/msvcrt/msvcrt.spec [iso-8859-1] (original) +++ trunk/reactos/dll/win32/msvcrt/msvcrt.spec [iso-8859-1] Fri Jul 9 14:33:03 2010 @@ -138,7 +138,7 @@ @ cdecl __crtCompareStringA(long long str long str long) kernel32.CompareStringA @ cdecl __crtCompareStringW(long long wstr long wstr long) kernel32.CompareStringW @ cdecl __crtGetLocaleInfoW(long long ptr long) kernel32.GetLocaleInfo -@ cdecl __crtGetStringTypeW(long long wstr long ptr) kernel32.GetStringTypeW +@ cdecl __crtGetStringTypeW(long long wstr long ptr) @ cdecl __crtLCMapStringA(long long str long ptr long long long) # stub __crtLCMapStringW @ cdecl __dllonexit(ptr ptr ptr) Modified: trunk/reactos/lib/sdk/crt/locale/locale.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/sdk/crt/locale/locale.…
============================================================================== --- trunk/reactos/lib/sdk/crt/locale/locale.c [iso-8859-1] (original) +++ trunk/reactos/lib/sdk/crt/locale/locale.c [iso-8859-1] Fri Jul 9 14:33:03 2010 @@ -901,3 +901,18 @@ { return __setlc_active; } + +/********************************************************************* + * __crtGetStringTypeW(MSVCRT.@) + * + * This function was accepting different number of arguments in older + * versions of msvcrt. + */ +BOOL CDECL __crtGetStringTypeW(DWORD unk, DWORD type, + wchar_t *buffer, int len, WORD *out) +{ + FIXME("(unk %x, type %x, wstr %p(%d), %p) partial stub\n", + unk, type, buffer, len, out); + + return GetStringTypeW(type, buffer, len, out); +}
14 years, 5 months
1
0
0
0
[fireball] 47977: [FORMATTING] - Fix wrong indentation.
by fireball@svn.reactos.org
Author: fireball Date: Fri Jul 9 13:04:33 2010 New Revision: 47977 URL:
http://svn.reactos.org/svn/reactos?rev=47977&view=rev
Log: [FORMATTING] - Fix wrong indentation. Modified: trunk/reactos/dll/win32/advapi32/misc/logon.c Modified: trunk/reactos/dll/win32/advapi32/misc/logon.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/advapi32/misc/lo…
============================================================================== --- trunk/reactos/dll/win32/advapi32/misc/logon.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/advapi32/misc/logon.c [iso-8859-1] Fri Jul 9 13:04:33 2010 @@ -763,17 +763,17 @@ GENERIC_ALL, OwnerSid); - RtlAllocateAndInitializeSid(&SystemAuthority, - 1, - SECURITY_LOCAL_SYSTEM_RID, - SECURITY_NULL_RID, - SECURITY_NULL_RID, - SECURITY_NULL_RID, - SECURITY_NULL_RID, - SECURITY_NULL_RID, - SECURITY_NULL_RID, - SECURITY_NULL_RID, - &LocalSystemSid); + RtlAllocateAndInitializeSid(&SystemAuthority, + 1, + SECURITY_LOCAL_SYSTEM_RID, + SECURITY_NULL_RID, + SECURITY_NULL_RID, + SECURITY_NULL_RID, + SECURITY_NULL_RID, + SECURITY_NULL_RID, + SECURITY_NULL_RID, + SECURITY_NULL_RID, + &LocalSystemSid); /* SID: S-1-5-18 */ RtlAddAccessAllowedAce(Dacl,
14 years, 5 months
1
0
0
0
← Newer
1
...
38
39
40
41
42
43
44
...
47
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
Results per page:
10
25
50
100
200