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
May 2014
----- 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
14 participants
437 discussions
Start a n
N
ew thread
[akhaldi] 63253: [CRT] * Update feof(). CORE-8080
by akhaldi@svn.reactos.org
Author: akhaldi Date: Mon May 12 13:17:31 2014 New Revision: 63253 URL:
http://svn.reactos.org/svn/reactos?rev=63253&view=rev
Log: [CRT] * Update feof(). CORE-8080 Modified: trunk/reactos/lib/sdk/crt/stdio/file.c Modified: trunk/reactos/lib/sdk/crt/stdio/file.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/sdk/crt/stdio/file.c?r…
============================================================================== --- trunk/reactos/lib/sdk/crt/stdio/file.c [iso-8859-1] (original) +++ trunk/reactos/lib/sdk/crt/stdio/file.c [iso-8859-1] Mon May 12 13:17:31 2014 @@ -2232,13 +2232,7 @@ */ int CDECL feof(FILE* file) { - int ret; - - _lock_file(file); - ret = file->_flag & _IOEOF; - _unlock_file(file); - - return ret; + return file->_flag & _IOEOF; } /*********************************************************************
10 years, 7 months
1
0
0
0
[akhaldi] 63252: [CRT] * Reduce difference to Wine. No code changes. CORE-8080
by akhaldi@svn.reactos.org
Author: akhaldi Date: Mon May 12 12:52:40 2014 New Revision: 63252 URL:
http://svn.reactos.org/svn/reactos?rev=63252&view=rev
Log: [CRT] * Reduce difference to Wine. No code changes. CORE-8080 Modified: trunk/reactos/lib/sdk/crt/stdlib/errno.c Modified: trunk/reactos/lib/sdk/crt/stdlib/errno.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/sdk/crt/stdlib/errno.c…
============================================================================== --- trunk/reactos/lib/sdk/crt/stdlib/errno.c [iso-8859-1] (original) +++ trunk/reactos/lib/sdk/crt/stdlib/errno.c [iso-8859-1] Mon May 12 12:52:40 2014 @@ -13,24 +13,36 @@ static _invalid_parameter_handler invalid_parameter_handler = NULL; -/* - * @implemented +/********************************************************************* + * _errno (MSVCRT.@) + */ +int CDECL *_errno(void) +{ + return &(msvcrt_get_thread_data()->thread_errno); +} + +/********************************************************************* + * __doserrno (MSVCRT.@) */ unsigned long* CDECL __doserrno(void) { return &(msvcrt_get_thread_data()->thread_doserrno); } -/* - * @implemented +/********************************************************************* + * _get_errno (MSVCRT.@) */ -int CDECL *_errno(void) +errno_t CDECL _get_errno(int *pValue) { - return &(msvcrt_get_thread_data()->thread_errno); + if (!pValue) + return EINVAL; + + *pValue = *_errno(); + return 0; } -/* - * @implemented +/********************************************************************* + * _get_doserrno (MSVCRT.@) */ errno_t CDECL _get_doserrno(unsigned long *pValue) { @@ -41,33 +53,21 @@ return 0; } -/* - * @implemented +/********************************************************************* + * _set_errno (MSVCRT.@) + */ +int CDECL _set_errno(int error) +{ + *_errno() = error; + return 0; +} + +/********************************************************************* + * _set_doserrno (MSVCRT.@) */ errno_t CDECL _set_doserrno(unsigned long error) { *__doserrno() = error; - return 0; -} - -/* - * @implemented - */ -errno_t CDECL _get_errno(int *pValue) -{ - if (!pValue) - return EINVAL; - - *pValue = *_errno(); - return 0; -} - -/* - * @implemented - */ -int CDECL _set_errno(int error) -{ - *_errno() = error; return 0; } @@ -124,8 +124,8 @@ } /****************************************************************************** -* _seterrormode (MSVCRT.@) -*/ + * _seterrormode (MSVCRT.@) + */ void CDECL _seterrormode(int mode) { SetErrorMode( mode ); @@ -134,8 +134,8 @@ /****************************************************************************** * _invalid_parameter (MSVCRT.@) */ -void CDECL _invalid_parameter(const wchar_t *expr, const wchar_t *func, - const wchar_t *file, unsigned int line, uintptr_t arg) +void __cdecl _invalid_parameter(const wchar_t *expr, const wchar_t *func, + const wchar_t *file, unsigned int line, uintptr_t arg) { if (invalid_parameter_handler) invalid_parameter_handler( expr, func, file, line, arg ); else @@ -163,4 +163,3 @@ invalid_parameter_handler = handler; return old; } -/* EOF */
10 years, 7 months
1
0
0
0
[akhaldi] 63251: [CRT] * Update tmpfile(). CORE-8080
by akhaldi@svn.reactos.org
Author: akhaldi Date: Mon May 12 12:50:55 2014 New Revision: 63251 URL:
http://svn.reactos.org/svn/reactos?rev=63251&view=rev
Log: [CRT] * Update tmpfile(). CORE-8080 Modified: trunk/reactos/lib/sdk/crt/stdio/file.c Modified: trunk/reactos/lib/sdk/crt/stdio/file.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/sdk/crt/stdio/file.c?r…
============================================================================== --- trunk/reactos/lib/sdk/crt/stdio/file.c [iso-8859-1] (original) +++ trunk/reactos/lib/sdk/crt/stdio/file.c [iso-8859-1] Mon May 12 12:50:55 2014 @@ -3346,16 +3346,20 @@ FILE* file = NULL; LOCK_FILES(); - fd = _open(filename, _O_CREAT | _O_BINARY | _O_RDWR | _O_TEMPORARY); + fd = _open(filename, _O_CREAT | _O_BINARY | _O_RDWR | _O_TEMPORARY, + _S_IREAD | _S_IWRITE); if (fd != -1 && (file = alloc_fp())) { - if (init_fp(file, fd, _O_RDWR) == -1) + if (init_fp(file, fd, _IORW) == -1) { file->_flag = 0; file = NULL; } else file->_tmpfname = _strdup(filename); } + + if(fd != -1 && !file) + _close(fd); UNLOCK_FILES(); return file; }
10 years, 7 months
1
0
0
0
[tfaber] 63250: [ICMP] - Fix socket leak. Spotted by Samuel & cppcheck Note: Wine has this in iphlpapi these days. Should probably sync. CORE-8208 #resolve
by tfaber@svn.reactos.org
Author: tfaber Date: Mon May 12 06:44:01 2014 New Revision: 63250 URL:
http://svn.reactos.org/svn/reactos?rev=63250&view=rev
Log: [ICMP] - Fix socket leak. Spotted by Samuel & cppcheck Note: Wine has this in iphlpapi these days. Should probably sync. CORE-8208 #resolve Modified: trunk/reactos/dll/win32/icmp/icmp_main.c Modified: trunk/reactos/dll/win32/icmp/icmp_main.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/icmp/icmp_main.c…
============================================================================== --- trunk/reactos/dll/win32/icmp/icmp_main.c [iso-8859-1] (original) +++ trunk/reactos/dll/win32/icmp/icmp_main.c [iso-8859-1] Mon May 12 06:44:01 2014 @@ -179,6 +179,7 @@ icp=HeapAlloc(GetProcessHeap(), 0, sizeof(*icp)); if (icp==NULL) { + closesocket(sid); SetLastError(IP_NO_RESOURCES); return INVALID_HANDLE_VALUE; }
10 years, 7 months
1
0
0
0
[tfaber] 63249: [CMD] - Fix mismatched allocation/free. Spotted by Samuel & cppcheck CORE-8207 #resolve
by tfaber@svn.reactos.org
Author: tfaber Date: Mon May 12 06:19:07 2014 New Revision: 63249 URL:
http://svn.reactos.org/svn/reactos?rev=63249&view=rev
Log: [CMD] - Fix mismatched allocation/free. Spotted by Samuel & cppcheck CORE-8207 #resolve Modified: trunk/reactos/base/shell/cmd/copy.c trunk/reactos/base/shell/cmd/replace.c Modified: trunk/reactos/base/shell/cmd/copy.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/cmd/copy.c?rev=…
============================================================================== --- trunk/reactos/base/shell/cmd/copy.c [iso-8859-1] (original) +++ trunk/reactos/base/shell/cmd/copy.c [iso-8859-1] Mon May 12 06:19:07 2014 @@ -200,7 +200,7 @@ } /* A page-aligned buffer usually give more speed */ - buffer = (LPBYTE)VirtualAlloc(NULL, BUFF_SIZE, MEM_COMMIT, PAGE_READWRITE); + buffer = VirtualAlloc(NULL, BUFF_SIZE, MEM_COMMIT, PAGE_READWRITE); if (buffer == NULL) { CloseHandle (hFileDest); Modified: trunk/reactos/base/shell/cmd/replace.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/cmd/replace.c?r…
============================================================================== --- trunk/reactos/base/shell/cmd/replace.c [iso-8859-1] (original) +++ trunk/reactos/base/shell/cmd/replace.c [iso-8859-1] Mon May 12 06:19:07 2014 @@ -160,7 +160,7 @@ } /* Get buffer for the copy process */ - buffer = (LPBYTE)VirtualAlloc(NULL, BUFF_SIZE, MEM_COMMIT, PAGE_READWRITE); + buffer = VirtualAlloc(NULL, BUFF_SIZE, MEM_COMMIT, PAGE_READWRITE); if (buffer == NULL) { CloseHandle (hFileDest); @@ -188,7 +188,7 @@ if (dwWritten != dwRead || CheckCtrlBreak(BREAK_INPUT)) { ConOutResPuts(STRING_COPY_ERROR3); - cmd_free (buffer); + VirtualFree (buffer, 0, MEM_RELEASE); CloseHandle (hFileDest); CloseHandle (hFileSrc); nErrorLevel = 1;
10 years, 7 months
1
0
0
0
[hbelusca] 63248: [NTVDM] Improve int32 callback stub (and sync int32.c too).
by hbelusca@svn.reactos.org
Author: hbelusca Date: Mon May 12 00:26:48 2014 New Revision: 63248 URL:
http://svn.reactos.org/svn/reactos?rev=63248&view=rev
Log: [NTVDM] Improve int32 callback stub (and sync int32.c too). Modified: trunk/reactos/subsystems/ntvdm/callback.c trunk/reactos/subsystems/ntvdm/int32.c Modified: trunk/reactos/subsystems/ntvdm/callback.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/ntvdm/callback.…
============================================================================== --- trunk/reactos/subsystems/ntvdm/callback.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/ntvdm/callback.c [iso-8859-1] Mon May 12 00:26:48 2014 @@ -75,8 +75,7 @@ 0xEB, 0xF5, // jmp BOP_SEQ (offset -11) // EXIT: - // 0x44, 0x44, // inc sp, inc sp - 0x83, 0xC4, 0x02, // add sp, 2 + 0x44, 0x44, // inc sp, inc sp 0xCF, // iret }; @@ -202,11 +201,13 @@ BYTE IntCallback[sizeof(Int16To32)/sizeof(BYTE)]; /* Check whether the 32-bit interrupt was already registered */ - // if (Int32Proc[IntNumber] != NULL) - // { - // DPRINT1("RegisterInt32: Interrupt 0x%X already registered!\n", IntNumber); - // return 0; - // } +#if 0 + if (Int32Proc[IntNumber] != NULL) + { + DPRINT1("RegisterInt32: Interrupt 0x%X already registered!\n", IntNumber); + return 0; + } +#endif /* Register the 32-bit interrupt handler */ Int32Proc[IntNumber] = IntHandler; Modified: trunk/reactos/subsystems/ntvdm/int32.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/subsystems/ntvdm/int32.c?r…
============================================================================== --- trunk/reactos/subsystems/ntvdm/int32.c [iso-8859-1] (original) +++ trunk/reactos/subsystems/ntvdm/int32.c [iso-8859-1] Mon May 12 00:26:48 2014 @@ -111,11 +111,8 @@ BiosCode[Offset++] = 0xF5; // EXIT: - // BiosCode[Offset++] = 0x44; // inc sp - // BiosCode[Offset++] = 0x44; // inc sp - BiosCode[Offset++] = 0x83; // add sp, 2 - BiosCode[Offset++] = 0xC4; - BiosCode[Offset++] = 0x02; + BiosCode[Offset++] = 0x44; // inc sp + BiosCode[Offset++] = 0x44; // inc sp BiosCode[Offset++] = 0xCF; // iret
10 years, 7 months
1
0
0
0
[tkreuzer] 63247: [DDK/XDK/NTOSKRNL/DRIVERS] Fix incompatible definition of a number of NTOSKRNL data imports. These imports are declared in MS DDK in a way that is usually not how you would declar...
by tkreuzer@svn.reactos.org
Author: tkreuzer Date: Sun May 11 23:11:16 2014 New Revision: 63247 URL:
http://svn.reactos.org/svn/reactos?rev=63247&view=rev
Log: [DDK/XDK/NTOSKRNL/DRIVERS] Fix incompatible definition of a number of NTOSKRNL data imports. These imports are declared in MS DDK in a way that is usually not how you would declare data imports. The proper way of doing it is using _DECLSPEC_INTRIN_TYPE(dllimport) or in this case NTKERNELAPI, which will cause the compiler to directly dereference the __imp__FooBar symbol. MS has declared some of these variables directly as pointers without using dllimport. This works with MS DDK, since it's import libraries contain aliases (like _FooBar) to the import symbols (__imp__FooBar). Neither MS LINK nor DLLTOOL create these aliases in the import libs, which is good, since hacks like these are dangerous. To make the original declarations work without using macros (which can conflict with other things, like for example the KdDebuggerEnabled member in KUSER_SHARED_DATA) these aliases have to be generated differently. Luckily both MSVC and GCC support a pragma that does exactly this. Fix the incompatible use in our drivers and the broen(!) use of KdDebuggerEnabled in kdcom (which was writing a PBOOLEAN value (FALSE == 0 == NULL, so no warning) into the location that is really a BOOLEAN, possibly overwriting other data. Finally get rid of a number of hacks in ntoskrnl, where prefixed versions were used to not conflict with the DDK definitions. Modified: trunk/reactos/drivers/base/kdcom/kdserial.c trunk/reactos/drivers/bus/acpi/compbatt/compmisc.c trunk/reactos/drivers/filters/mountmgr/device.c trunk/reactos/drivers/ksfilter/ks/event.c trunk/reactos/drivers/ksfilter/ks/pin.c trunk/reactos/drivers/network/afd/afd/bind.c trunk/reactos/drivers/network/afd/afd/select.c trunk/reactos/drivers/network/afd/afd/tdi.c trunk/reactos/drivers/network/tcpip/tcpip/dispatch.c trunk/reactos/drivers/storage/floppy/floppy.c trunk/reactos/drivers/wdm/audio/legacy/wdmaud/control.c trunk/reactos/drivers/wdm/audio/legacy/wdmaud/deviface.c trunk/reactos/drivers/wdm/audio/legacy/wdmaud/mmixer.c trunk/reactos/drivers/wdm/audio/legacy/wdmaud/sup.c trunk/reactos/drivers/wdm/audio/sysaudio/deviface.c trunk/reactos/drivers/wdm/audio/sysaudio/pin.c trunk/reactos/include/ddk/ntddk.h trunk/reactos/include/ddk/ntifs.h trunk/reactos/include/ddk/wdm.h trunk/reactos/include/reactos/libs/pseh/pseh3.h trunk/reactos/include/xdk/ccfuncs.h trunk/reactos/include/xdk/extypes.h trunk/reactos/include/xdk/fsrtlfuncs.h trunk/reactos/include/xdk/haltypes.h trunk/reactos/include/xdk/ia64/ke.h trunk/reactos/include/xdk/iotypes.h trunk/reactos/include/xdk/kdfuncs.h trunk/reactos/include/xdk/ketypes.h trunk/reactos/include/xdk/mmtypes.h trunk/reactos/include/xdk/ntifs.template.h trunk/reactos/include/xdk/obtypes.h trunk/reactos/include/xdk/rtltypes.h trunk/reactos/include/xdk/sefuncs.h trunk/reactos/include/xdk/wdm.template.h trunk/reactos/lib/rtl/nls.c trunk/reactos/ntoskrnl/ex/event.c trunk/reactos/ntoskrnl/ex/sem.c trunk/reactos/ntoskrnl/fsrtl/fsrtlpc.c trunk/reactos/ntoskrnl/include/internal/fsrtl.h trunk/reactos/ntoskrnl/include/internal/kd.h trunk/reactos/ntoskrnl/include/internal/kd64.h trunk/reactos/ntoskrnl/include/ntoskrnl.h trunk/reactos/ntoskrnl/kd64/kdapi.c trunk/reactos/ntoskrnl/kd64/kddata.c trunk/reactos/ntoskrnl/kd64/kdinit.c trunk/reactos/ntoskrnl/ntoskrnl.spec trunk/reactos/tools/spec2def/spec2def.c trunk/reactos/win32ss/gdi/eng/engevent.c trunk/reactos/win32ss/user/ntuser/main.c trunk/reactos/win32ss/user/ntuser/message.c trunk/reactos/win32ss/user/ntuser/misc.c Modified: trunk/reactos/drivers/base/kdcom/kdserial.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/base/kdcom/kdseria…
============================================================================== --- trunk/reactos/drivers/base/kdcom/kdserial.c [iso-8859-1] (original) +++ trunk/reactos/drivers/base/kdcom/kdserial.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -38,7 +38,7 @@ * \brief Receives data from the KD port and fills a buffer. * \param Buffer Pointer to a buffer that receives the data. * \param Size Size of data to receive in bytes. - * \return KDP_PACKET_RECEIVED if successful. + * \return KDP_PACKET_RECEIVED if successful. * KDP_PACKET_TIMEOUT if the receice timed out. */ KDP_STATUS @@ -69,7 +69,7 @@ * \name KdpReceivePacketLeader * \brief Receives a packet leadr from the KD port. * \param PacketLeader Pointer to an ULONG that receives the packet leader. - * \return KDP_PACKET_RECEIVED if successful. + * \return KDP_PACKET_RECEIVED if successful. * KDP_PACKET_TIMEOUT if the receive timed out. * KDP_PACKET_RESEND if a breakin byte was detected. */ @@ -141,7 +141,7 @@ while (Index < 4); /* Enable the debugger */ - KdDebuggerNotPresent = FALSE; + KD_DEBUGGER_NOT_PRESENT = FALSE; SharedUserData->KdDebuggerEnabled |= 0x00000002; /* Return the received packet leader */ Modified: trunk/reactos/drivers/bus/acpi/compbatt/compmisc.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/bus/acpi/compbatt/…
============================================================================== --- trunk/reactos/drivers/bus/acpi/compbatt/compmisc.c [iso-8859-1] (original) +++ trunk/reactos/drivers/bus/acpi/compbatt/compmisc.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -14,7 +14,7 @@ NTSTATUS NTAPI -BatteryIoctl(IN ULONG IoControlCode, +BatteryIoctl(IN ULONG IoControlCode, IN PDEVICE_OBJECT DeviceObject, IN PVOID InputBuffer, IN ULONG InputBufferLength, @@ -50,11 +50,11 @@ KeWaitForSingleObject(&Event, Executive, KernelMode, FALSE, NULL); Status = IoStatusBlock.Status; } - + /* Print failure */ if (!(NT_SUCCESS(Status)) && (CompBattDebug & 8)) DbgPrint("BatteryIoctl: Irp failed - %x\n", Status); - + /* Done */ if (CompBattDebug & 0x100) DbgPrint("CompBatt: EXITING BatteryIoctl\n"); } @@ -64,7 +64,7 @@ if (CompBattDebug & 8) DbgPrint("BatteryIoctl: couldn't create Irp\n"); Status = STATUS_INSUFFICIENT_RESOURCES; } - + /* Return status */ return Status; } @@ -82,7 +82,7 @@ PFILE_OBJECT LocalFileObject; HANDLE DeviceHandle; PAGED_CODE(); - + /* Open a file object handle to the device */ InitializeObjectAttributes(&ObjectAttributes, DeviceName, 0, NULL, NULL); Status = ZwCreateFile(&DeviceHandle, @@ -101,7 +101,7 @@ /* Reference the file object */ Status = ObReferenceObjectByHandle(DeviceHandle, 0, - IoFileObjectType, + *IoFileObjectType, KernelMode, (PVOID)&LocalFileObject, NULL); @@ -111,11 +111,11 @@ *FileObject = LocalFileObject; *DeviceObject = IoGetRelatedDeviceObject(LocalFileObject); } - + /* Close the handle */ ZwClose(DeviceHandle); } - + /* Return status */ return Status; } Modified: trunk/reactos/drivers/filters/mountmgr/device.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/filters/mountmgr/d…
============================================================================== --- trunk/reactos/drivers/filters/mountmgr/device.c [iso-8859-1] (original) +++ trunk/reactos/drivers/filters/mountmgr/device.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -1552,7 +1552,7 @@ } /* Reference it */ - Status = ObReferenceObjectByHandle(Handle, 0, IoFileObjectType, KernelMode, (PVOID *)&FileObject, NULL); + Status = ObReferenceObjectByHandle(Handle, 0, *IoFileObjectType, KernelMode, (PVOID *)&FileObject, NULL); if (!NT_SUCCESS(Status)) { goto Cleanup; Modified: trunk/reactos/drivers/ksfilter/ks/event.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/event.…
============================================================================== --- trunk/reactos/drivers/ksfilter/ks/event.c [iso-8859-1] (original) +++ trunk/reactos/drivers/ksfilter/ks/event.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -99,7 +99,7 @@ KSEVENT Event; PKSEVENT_ITEM EventItem, FoundEventItem; PKSEVENTDATA EventData; - const KSEVENT_SET* FoundEventSet; + const KSEVENT_SET *FoundEventSet; PKSEVENT_ENTRY EventEntry; ULONG Index, SubIndex, Size; PVOID Object; @@ -234,7 +234,7 @@ if (EventData->NotificationType == KSEVENTF_SEMAPHORE_HANDLE) { /* get semaphore object handle */ - Status = ObReferenceObjectByHandle(EventData->SemaphoreHandle.Semaphore, SEMAPHORE_MODIFY_STATE, ExSemaphoreObjectType, Irp->RequestorMode, &Object, NULL); + Status = ObReferenceObjectByHandle(EventData->SemaphoreHandle.Semaphore, SEMAPHORE_MODIFY_STATE, *ExSemaphoreObjectType, Irp->RequestorMode, &Object, NULL); if (!NT_SUCCESS(Status)) { @@ -245,7 +245,7 @@ else if (EventData->NotificationType == KSEVENTF_EVENT_HANDLE) { /* get event object handle */ - Status = ObReferenceObjectByHandle(EventData->EventHandle.Event, EVENT_MODIFY_STATE, ExEventObjectType, Irp->RequestorMode, &Object, NULL); + Status = ObReferenceObjectByHandle(EventData->EventHandle.Event, EVENT_MODIFY_STATE, *ExEventObjectType, Irp->RequestorMode, &Object, NULL); if (!NT_SUCCESS(Status)) { Modified: trunk/reactos/drivers/ksfilter/ks/pin.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/ksfilter/ks/pin.c?…
============================================================================== --- trunk/reactos/drivers/ksfilter/ks/pin.c [iso-8859-1] (original) +++ trunk/reactos/drivers/ksfilter/ks/pin.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -193,7 +193,7 @@ { Mode = ExGetPreviousMode(); - Status = ObReferenceObjectByHandle(*Handle, SYNCHRONIZE | DIRECTORY_QUERY, IoFileObjectType, Mode, (PVOID*)&FileObject, NULL); + Status = ObReferenceObjectByHandle(*Handle, SYNCHRONIZE | DIRECTORY_QUERY, *IoFileObjectType, Mode, (PVOID*)&FileObject, NULL); DPRINT("IKsPin_PinMasterClock ObReferenceObjectByHandle %lx\n", Status); if (NT_SUCCESS(Status)) @@ -2221,7 +2221,7 @@ pResolution = &Resolution; } - Status = KsAllocateDefaultClockEx(&This->DefaultClock, + Status = KsAllocateDefaultClockEx(&This->DefaultClock, (PVOID)&This->Pin, (PFNKSSETTIMER)This->Pin.Descriptor->Dispatch->Clock->SetTimer, (PFNKSCANCELTIMER)This->Pin.Descriptor->Dispatch->Clock->CancelTimer, @@ -2265,7 +2265,7 @@ return STATUS_NOT_IMPLEMENTED; } -static KSDISPATCH_TABLE PinDispatchTable = +static KSDISPATCH_TABLE PinDispatchTable = { IKsPin_DispatchDeviceIoControl, KsDispatchInvalidDeviceRequest, @@ -2329,10 +2329,10 @@ DPRINT("KspCreatePin Index %lu FileAlignment %lx\n", Index, Descriptor->AllocatorFraming->FramingItem[Index].FileAlignment); DPRINT("KspCreatePin Index %lu MemoryTypeWeight %lx\n", Index, Descriptor->AllocatorFraming->FramingItem[Index].MemoryTypeWeight); DPRINT("KspCreatePin Index %lu PhysicalRange MinFrameSize %lu MaxFrameSize %lu Stepping %lu\n", Index, Descriptor->AllocatorFraming->FramingItem[Index].PhysicalRange.MinFrameSize, - Descriptor->AllocatorFraming->FramingItem[Index].PhysicalRange.MaxFrameSize, + Descriptor->AllocatorFraming->FramingItem[Index].PhysicalRange.MaxFrameSize, Descriptor->AllocatorFraming->FramingItem[Index].PhysicalRange.Stepping); - DPRINT("KspCreatePin Index %lu FramingRange MinFrameSize %lu MaxFrameSize %lu Stepping %lu InPlaceWeight %lu NotInPlaceWeight %lu\n", + DPRINT("KspCreatePin Index %lu FramingRange MinFrameSize %lu MaxFrameSize %lu Stepping %lu InPlaceWeight %lu NotInPlaceWeight %lu\n", Index, Descriptor->AllocatorFraming->FramingItem[Index].FramingRange.Range.MinFrameSize, Descriptor->AllocatorFraming->FramingItem[Index].FramingRange.Range.MaxFrameSize, Modified: trunk/reactos/drivers/network/afd/afd/bind.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/network/afd/afd/bi…
============================================================================== --- trunk/reactos/drivers/network/afd/afd/bind.c [iso-8859-1] (original) +++ trunk/reactos/drivers/network/afd/afd/bind.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -105,7 +105,7 @@ 0, NULL, MAXIMUM_ALLOWED, - IoFileObjectType, + *IoFileObjectType, Irp->RequestorMode, &UserHandle); if (NT_SUCCESS(Status)) Modified: trunk/reactos/drivers/network/afd/afd/select.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/network/afd/afd/se…
============================================================================== --- trunk/reactos/drivers/network/afd/afd/select.c [iso-8859-1] (original) +++ trunk/reactos/drivers/network/afd/afd/select.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -289,7 +289,7 @@ Status = ObReferenceObjectByHandle( (PVOID)EventSelectInfo-> EventObject, EVENT_ALL_ACCESS, - ExEventObjectType, + *ExEventObjectType, UserMode, (PVOID *)&FCB->EventSelect, NULL ); @@ -346,7 +346,7 @@ Status = ObReferenceObjectByHandle(EnumReq->Event, EVENT_ALL_ACCESS, - ExEventObjectType, + *ExEventObjectType, UserMode, (PVOID *)&UserEvent, NULL); Modified: trunk/reactos/drivers/network/afd/afd/tdi.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/network/afd/afd/td…
============================================================================== --- trunk/reactos/drivers/network/afd/afd/tdi.c [iso-8859-1] (original) +++ trunk/reactos/drivers/network/afd/afd/tdi.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -144,7 +144,7 @@ if (NT_SUCCESS(Status)) { Status = ObReferenceObjectByHandle(*Handle, /* Handle to open file */ GENERIC_READ | GENERIC_WRITE | SYNCHRONIZE, /* Access mode */ - IoFileObjectType, /* Object type */ + *IoFileObjectType, /* Object type */ KernelMode, /* Access mode */ (PVOID*)Object, /* Pointer to object */ NULL); /* Handle information */ Modified: trunk/reactos/drivers/network/tcpip/tcpip/dispatch.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/network/tcpip/tcpi…
============================================================================== --- trunk/reactos/drivers/network/tcpip/tcpip/dispatch.c [iso-8859-1] (original) +++ trunk/reactos/drivers/network/tcpip/tcpip/dispatch.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -173,7 +173,7 @@ case TDI_CONNECT: DequeuedIrp = TCPRemoveIRP(TranContext->Handle.ConnectionContext, Irp); break; - + case TDI_DISCONNECT: Connection = (PCONNECTION_ENDPOINT)TranContext->Handle.ConnectionContext; @@ -303,7 +303,7 @@ Status = ObReferenceObjectByHandle( Parameters->AddressHandle, 0, - IoFileObjectType, + *IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); @@ -511,7 +511,7 @@ Status = STATUS_INVALID_PARAMETER; goto done; } - + Status = DispPrepareIrpForCancel (TranContext->Handle.ConnectionContext, Irp, @@ -716,7 +716,7 @@ case TDI_CONNECTION_FILE: Endpoint = (PCONNECTION_ENDPOINT)TranContext->Handle.ConnectionContext; - + Address->TAAddressCount = 1; Address->Address[0].AddressLength = TDI_ADDRESS_LENGTH_IP; Address->Address[0].AddressType = TDI_ADDRESS_TYPE_IP; @@ -761,12 +761,12 @@ case TDI_QUERY_MAX_DATAGRAM_INFO: { PTDI_MAX_DATAGRAM_INFO MaxDatagramInfo; - + if (MmGetMdlByteCount(Irp->MdlAddress) < sizeof(*MaxDatagramInfo)) { TI_DbgPrint(MID_TRACE, ("MDL buffer too small.\n")); return STATUS_BUFFER_TOO_SMALL; } - + MaxDatagramInfo = (PTDI_MAX_DATAGRAM_INFO) MmGetSystemAddressForMdl(Irp->MdlAddress); @@ -1560,7 +1560,7 @@ IF->Netmask.Type = IP_ADDRESS_V4; IF->Netmask.Address.IPv4Address = IpAddrChange->Netmask; - + IF->Broadcast.Type = IP_ADDRESS_V4; IF->Broadcast.Address.IPv4Address = IF->Unicast.Address.IPv4Address | Modified: trunk/reactos/drivers/storage/floppy/floppy.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/storage/floppy/flo…
============================================================================== --- trunk/reactos/drivers/storage/floppy/floppy.c [iso-8859-1] (original) +++ trunk/reactos/drivers/storage/floppy/floppy.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -761,9 +761,9 @@ HeadLoadTime = SPECIFY_HLT_500K; HeadUnloadTime = SPECIFY_HUT_500K; StepRateTime = SPECIFY_SRT_500K; - + INFO_(FLOPPY, "InitController: setting data rate\n"); - + /* Set data rate */ if(HwSetDataRate(ControllerInfo, DRSR_DSEL_500KBPS) != STATUS_SUCCESS) { @@ -1176,7 +1176,7 @@ return STATUS_INSUFFICIENT_RESOURCES; } - if(ObReferenceObjectByHandle(ThreadHandle, STANDARD_RIGHTS_ALL, PsThreadType, KernelMode, &QueueThreadObject, NULL) != STATUS_SUCCESS) + if(ObReferenceObjectByHandle(ThreadHandle, STANDARD_RIGHTS_ALL, *PsThreadType, KernelMode, &QueueThreadObject, NULL) != STATUS_SUCCESS) { WARN_(FLOPPY, "Unable to reference returned thread handle; failing init\n"); return STATUS_UNSUCCESSFUL; Modified: trunk/reactos/drivers/wdm/audio/legacy/wdmaud/control.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/legacy/w…
============================================================================== --- trunk/reactos/drivers/wdm/audio/legacy/wdmaud/control.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/legacy/wdmaud/control.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -97,7 +97,7 @@ DPRINT("WdmAudControlDeviceState\n"); - Status = ObReferenceObjectByHandle(DeviceInfo->hDevice, GENERIC_READ | GENERIC_WRITE, IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); + Status = ObReferenceObjectByHandle(DeviceInfo->hDevice, GENERIC_READ | GENERIC_WRITE, *IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); if (!NT_SUCCESS(Status)) { DPRINT1("Error: invalid device handle provided %p Type %x\n", DeviceInfo->hDevice, DeviceInfo->DeviceType); @@ -197,7 +197,7 @@ NTSTATUS Status; /* Get sysaudio pin file object */ - Status = ObReferenceObjectByHandle(DeviceInfo->hDevice, GENERIC_WRITE, IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); + Status = ObReferenceObjectByHandle(DeviceInfo->hDevice, GENERIC_WRITE, *IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); if (!NT_SUCCESS(Status)) { DPRINT1("Invalid buffer handle %p\n", DeviceInfo->hDevice); @@ -290,7 +290,7 @@ DPRINT("WdmAudResetStream\n"); - Status = ObReferenceObjectByHandle(DeviceInfo->hDevice, GENERIC_READ | GENERIC_WRITE, IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); + Status = ObReferenceObjectByHandle(DeviceInfo->hDevice, GENERIC_READ | GENERIC_WRITE, *IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); if (!NT_SUCCESS(Status)) { DPRINT1("Error: invalid device handle provided %p Type %x\n", DeviceInfo->hDevice, DeviceInfo->DeviceType); @@ -528,7 +528,7 @@ ASSERT(DeviceInfo); /* now get sysaudio file object */ - Status = ObReferenceObjectByHandle(DeviceInfo->hDevice, GENERIC_WRITE, IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); + Status = ObReferenceObjectByHandle(DeviceInfo->hDevice, GENERIC_WRITE, *IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); if (!NT_SUCCESS(Status)) { DPRINT1("Invalid pin handle %p\n", DeviceInfo->hDevice); Modified: trunk/reactos/drivers/wdm/audio/legacy/wdmaud/deviface.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/legacy/w…
============================================================================== --- trunk/reactos/drivers/wdm/audio/legacy/wdmaud/deviface.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/legacy/wdmaud/deviface.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -165,7 +165,7 @@ } /* get the file object */ - Status = ObReferenceObjectByHandle(hSysAudio, FILE_READ_DATA | FILE_WRITE_DATA, IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); + Status = ObReferenceObjectByHandle(hSysAudio, FILE_READ_DATA | FILE_WRITE_DATA, *IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); if (!NT_SUCCESS(Status)) { DPRINT1("Failed to reference FileObject %x\n", Status); @@ -200,7 +200,7 @@ } /* failed to register device interface - * create a symbolic link instead + * create a symbolic link instead */ DeviceExtension->DeviceInterfaceSupport = FALSE; Modified: trunk/reactos/drivers/wdm/audio/legacy/wdmaud/mmixer.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/legacy/w…
============================================================================== --- trunk/reactos/drivers/wdm/audio/legacy/wdmaud/mmixer.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/legacy/wdmaud/mmixer.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -202,7 +202,7 @@ PFILE_OBJECT FileObject; /* get file object */ - Status = ObReferenceObjectByHandle(hMixer, GENERIC_READ | GENERIC_WRITE, IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); + Status = ObReferenceObjectByHandle(hMixer, GENERIC_READ | GENERIC_WRITE, *IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); if (!NT_SUCCESS(Status)) { DPRINT("failed to reference %p with %lx\n", hMixer, Status); @@ -420,7 +420,7 @@ if (DeviceInfo->u.hNotifyEvent) { - Status = ObReferenceObjectByHandle(DeviceInfo->u.hNotifyEvent, EVENT_MODIFY_STATE, ExEventObjectType, UserMode, (LPVOID*)&EventObject, NULL); + Status = ObReferenceObjectByHandle(DeviceInfo->u.hNotifyEvent, EVENT_MODIFY_STATE, *ExEventObjectType, UserMode, (LPVOID*)&EventObject, NULL); if (!NT_SUCCESS(Status)) { Modified: trunk/reactos/drivers/wdm/audio/legacy/wdmaud/sup.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/legacy/w…
============================================================================== --- trunk/reactos/drivers/wdm/audio/legacy/wdmaud/sup.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/legacy/wdmaud/sup.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -420,7 +420,7 @@ if (FileObject) { - Status = ObReferenceObjectByHandle(hDevice, FILE_READ_DATA | FILE_WRITE_DATA, IoFileObjectType, KernelMode, (PVOID*)FileObject, NULL); + Status = ObReferenceObjectByHandle(hDevice, FILE_READ_DATA | FILE_WRITE_DATA, *IoFileObjectType, KernelMode, (PVOID*)FileObject, NULL); if (!NT_SUCCESS(Status)) { Modified: trunk/reactos/drivers/wdm/audio/sysaudio/deviface.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/sysaudio…
============================================================================== --- trunk/reactos/drivers/wdm/audio/sysaudio/deviface.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/sysaudio/deviface.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -50,7 +50,7 @@ return Status; } - Status = ObReferenceObjectByHandle(NodeHandle, GENERIC_READ | GENERIC_WRITE, IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); + Status = ObReferenceObjectByHandle(NodeHandle, GENERIC_READ | GENERIC_WRITE, *IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); if (!NT_SUCCESS(Status)) { ZwClose(NodeHandle); Modified: trunk/reactos/drivers/wdm/audio/sysaudio/pin.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/wdm/audio/sysaudio…
============================================================================== --- trunk/reactos/drivers/wdm/audio/sysaudio/pin.c [iso-8859-1] (original) +++ trunk/reactos/drivers/wdm/audio/sysaudio/pin.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -35,7 +35,7 @@ ASSERT(Context); /* acquire real pin file object */ - Status = ObReferenceObjectByHandle(Context->Handle, GENERIC_WRITE, IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); + Status = ObReferenceObjectByHandle(Context->Handle, GENERIC_WRITE, *IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); if (!NT_SUCCESS(Status)) { Irp->IoStatus.Information = 0; @@ -94,7 +94,7 @@ } /* acquire real pin file object */ - Status = ObReferenceObjectByHandle(Context->Handle, GENERIC_WRITE, IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); + Status = ObReferenceObjectByHandle(Context->Handle, GENERIC_WRITE, *IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); if (!NT_SUCCESS(Status)) { DPRINT1("failed\n"); @@ -235,8 +235,8 @@ } Status = ObReferenceObjectByHandle(PinHandle, - GENERIC_READ | GENERIC_WRITE, - IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); + GENERIC_READ | GENERIC_WRITE, + *IoFileObjectType, KernelMode, (PVOID*)&FileObject, NULL); if (!NT_SUCCESS(Status)) { Modified: trunk/reactos/include/ddk/ntddk.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ddk/ntddk.h?rev=63…
============================================================================== --- trunk/reactos/include/ddk/ntddk.h [iso-8859-1] (original) +++ trunk/reactos/include/ddk/ntddk.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -1666,14 +1666,12 @@ #endif } HAL_DISPATCH, *PHAL_DISPATCH; -/* GCC/MSVC and WDK compatible declaration */ -extern NTKERNELAPI HAL_DISPATCH HalDispatchTable; - -#if defined(_NTOSKRNL_) || defined(_BLDR_) +#ifdef _NTSYSTEM_ +extern HAL_DISPATCH HalDispatchTable; #define HALDISPATCH (&HalDispatchTable) #else -/* This is a WDK compatibility definition */ -#define HalDispatchTable (&HalDispatchTable) +extern PHAL_DISPATCH HalDispatchTable; +__CREATE_NTOS_DATA_IMPORT_ALIAS(HalDispatchTable) #define HALDISPATCH HalDispatchTable #endif Modified: trunk/reactos/include/ddk/ntifs.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ddk/ntifs.h?rev=63…
============================================================================== --- trunk/reactos/include/ddk/ntifs.h [iso-8859-1] (original) +++ trunk/reactos/include/ddk/ntifs.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -870,11 +870,11 @@ (NTAPI *PRTL_FREE_STRING_ROUTINE)( _In_ __drv_freesMem(Mem) _Post_invalid_ PVOID Buffer); -extern const PRTL_ALLOCATE_STRING_ROUTINE RtlAllocateStringRoutine; -extern const PRTL_FREE_STRING_ROUTINE RtlFreeStringRoutine; +extern NTKERNELAPI const PRTL_ALLOCATE_STRING_ROUTINE RtlAllocateStringRoutine; +extern NTKERNELAPI const PRTL_FREE_STRING_ROUTINE RtlFreeStringRoutine; #if _WIN32_WINNT >= 0x0600 -extern const PRTL_REALLOCATE_STRING_ROUTINE RtlReallocateStringRoutine; +extern NTKERNELAPI const PRTL_REALLOCATE_STRING_ROUTINE RtlReallocateStringRoutine; #endif _Function_class_(RTL_HEAP_COMMIT_ROUTINE) @@ -4937,35 +4937,13 @@ _In_ BOOLEAN SafeToRecurse); #endif /* (NTDDI_VERSION >= NTDDI_VISTA) */ -#define DO_VERIFY_VOLUME 0x00000002 -#define DO_BUFFERED_IO 0x00000004 -#define DO_EXCLUSIVE 0x00000008 -#define DO_DIRECT_IO 0x00000010 -#define DO_MAP_IO_BUFFER 0x00000020 -#define DO_DEVICE_HAS_NAME 0x00000040 -#define DO_DEVICE_INITIALIZING 0x00000080 -#define DO_SYSTEM_BOOT_PARTITION 0x00000100 -#define DO_LONG_TERM_REQUESTS 0x00000200 -#define DO_NEVER_LAST_DEVICE 0x00000400 -#define DO_SHUTDOWN_REGISTERED 0x00000800 -#define DO_BUS_ENUMERATED_DEVICE 0x00001000 -#define DO_POWER_PAGABLE 0x00002000 -#define DO_POWER_INRUSH 0x00004000 -#define DO_LOW_PRIORITY_FILESYSTEM 0x00010000 -#define DO_SUPPORTS_TRANSACTIONS 0x00040000 -#define DO_FORCE_NEITHER_IO 0x00080000 -#define DO_VOLUME_DEVICE_OBJECT 0x00100000 -#define DO_SYSTEM_SYSTEM_PARTITION 0x00200000 -#define DO_SYSTEM_CRITICAL_PARTITION 0x00400000 -#define DO_DISALLOW_EXECUTE 0x00800000 - -extern KSPIN_LOCK IoStatisticsLock; -extern ULONG IoReadOperationCount; -extern ULONG IoWriteOperationCount; -extern ULONG IoOtherOperationCount; -extern LARGE_INTEGER IoReadTransferCount; -extern LARGE_INTEGER IoWriteTransferCount; -extern LARGE_INTEGER IoOtherTransferCount; +extern NTKERNELAPI KSPIN_LOCK IoStatisticsLock; +extern NTKERNELAPI ULONG IoReadOperationCount; +extern NTKERNELAPI ULONG IoWriteOperationCount; +extern NTKERNELAPI ULONG IoOtherOperationCount; +extern NTKERNELAPI LARGE_INTEGER IoReadTransferCount; +extern NTKERNELAPI LARGE_INTEGER IoWriteTransferCount; +extern NTKERNELAPI LARGE_INTEGER IoOtherTransferCount; #define IO_FILE_OBJECT_NON_PAGED_POOL_CHARGE 64 #define IO_FILE_OBJECT_PAGED_POOL_CHARGE 1024 @@ -5731,6 +5709,7 @@ ((PSECURITY_SUBJECT_CONTEXT) SubjectContext)->PrimaryToken ) extern NTKERNELAPI PSE_EXPORTS SeExports; + /****************************************************************************** * Process Manager Functions * ******************************************************************************/ @@ -8413,26 +8392,31 @@ (InterlockedDecrement((LONG volatile *)&((FL)->LockRequestsInProgress)));\ } -/* GCC compatible definition, MS one is retarded */ -extern NTKERNELAPI const UCHAR * const FsRtlLegalAnsiCharacterArray; -#define LEGAL_ANSI_CHARACTER_ARRAY FsRtlLegalAnsiCharacterArray +#ifdef _NTSYSTEM_ +extern const UCHAR * const FsRtlLegalAnsiCharacterArray; +#define LEGAL_ANSI_CHARACTER_ARRAY FsRtlLegalAnsiCharacterArray +#else +extern const UCHAR * const *FsRtlLegalAnsiCharacterArray; +__CREATE_NTOS_DATA_IMPORT_ALIAS(FsRtlLegalAnsiCharacterArray) +#define LEGAL_ANSI_CHARACTER_ARRAY (*FsRtlLegalAnsiCharacterArray) +#endif #define FsRtlIsAnsiCharacterWild(C) ( \ - FlagOn(FsRtlLegalAnsiCharacterArray[(UCHAR)(C)], FSRTL_WILD_CHARACTER ) \ + FlagOn(LEGAL_ANSI_CHARACTER_ARRAY[(UCHAR)(C)], FSRTL_WILD_CHARACTER ) \ ) #define FsRtlIsAnsiCharacterLegalFat(C, WILD) ( \ - FlagOn(FsRtlLegalAnsiCharacterArray[(UCHAR)(C)], (FSRTL_FAT_LEGAL) | \ + FlagOn(LEGAL_ANSI_CHARACTER_ARRAY[(UCHAR)(C)], (FSRTL_FAT_LEGAL) | \ ((WILD) ? FSRTL_WILD_CHARACTER : 0 )) \ ) #define FsRtlIsAnsiCharacterLegalHpfs(C, WILD) ( \ - FlagOn(FsRtlLegalAnsiCharacterArray[(UCHAR)(C)], (FSRTL_HPFS_LEGAL) | \ + FlagOn(LEGAL_ANSI_CHARACTER_ARRAY[(UCHAR)(C)], (FSRTL_HPFS_LEGAL) | \ ((WILD) ? FSRTL_WILD_CHARACTER : 0 )) \ ) #define FsRtlIsAnsiCharacterLegalNtfs(C, WILD) ( \ - FlagOn(FsRtlLegalAnsiCharacterArray[(UCHAR)(C)], (FSRTL_NTFS_LEGAL) | \ + FlagOn(LEGAL_ANSI_CHARACTER_ARRAY[(UCHAR)(C)], (FSRTL_NTFS_LEGAL) | \ ((WILD) ? FSRTL_WILD_CHARACTER : 0 )) \ ) @@ -8460,7 +8444,7 @@ #define FsRtlIsUnicodeCharacterWild(C) ( \ (((C) >= 0x40) ? \ FALSE : \ - FlagOn(FsRtlLegalAnsiCharacterArray[(C)], FSRTL_WILD_CHARACTER )) \ + FlagOn(LEGAL_ANSI_CHARACTER_ARRAY[(C)], FSRTL_WILD_CHARACTER )) \ ) #define FsRtlInitPerFileContext( _fc, _owner, _inst, _cb) \ @@ -8623,7 +8607,7 @@ (((PSECTION_OBJECT_POINTERS)(FO)->SectionObjectPointer)->SharedCacheMap != NULL) \ ) -extern ULONG CcFastMdlReadWait; +extern NTKERNELAPI ULONG CcFastMdlReadWait; #if (NTDDI_VERSION >= NTDDI_WIN2K) @@ -11005,13 +10989,14 @@ #define HalGetDmaAlignmentRequirement() 1L #endif -extern NTKERNELAPI PUSHORT NlsOemLeadByteInfo; -#define NLS_OEM_LEAD_BYTE_INFO NlsOemLeadByteInfo - -#ifdef NLS_MB_CODE_PAGE_TAG -#undef NLS_MB_CODE_PAGE_TAG +#ifdef _NTSYSTEM_ +extern PUSHORT NlsOemLeadByteInfo; +#define NLS_OEM_LEAD_BYTE_INFO NlsOemLeadByteInfo +#else +extern PUSHORT *NlsOemLeadByteInfo; +__CREATE_NTOS_DATA_IMPORT_ALIAS(NlsOemLeadByteInfo) +#define NLS_OEM_LEAD_BYTE_INFO (*NlsOemLeadByteInfo) #endif -#define NLS_MB_CODE_PAGE_TAG NlsMbOemCodePageTag #if (NTDDI_VERSION >= NTDDI_VISTA) Modified: trunk/reactos/include/ddk/wdm.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/ddk/wdm.h?rev=6324…
============================================================================== --- trunk/reactos/include/ddk/wdm.h [iso-8859-1] (original) +++ trunk/reactos/include/ddk/wdm.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -25,6 +25,9 @@ #ifndef _WDMDDK_ #define _WDMDDK_ +// TEMP HACK! +#define _PROPER_NT_EXPORTS 1 + #define WDM_MAJORVERSION 0x06 #define WDM_MINORVERSION 0x00 @@ -82,10 +85,13 @@ #endif /* For ReactOS */ -#if !defined(_NTOSKRNL_) && !defined(_BLDR_) +#if !defined(_NTOSKRNL_) && !defined(_BLDR_) && !defined(_NTSYSTEM_) #define NTKERNELAPI DECLSPEC_IMPORT #else #define NTKERNELAPI +#ifndef _NTSYSTEM_ +#define _NTSYSTEM_ +#endif #endif #if defined(_X86_) && !defined(_NTHAL_) @@ -129,6 +135,29 @@ #define ALLOC_DATA_PRAGMA 1 #endif +#endif /* _MSC_VER */ + +/* These macros are used to create aliases for imported data. We need to do + this to have declarations that are compatible with MS DDK */ +#ifdef _M_IX86 +#define __SYMBOL(_Name) "_"#_Name +#define __IMPORTSYMBOL(_Name) "__imp__"#_Name +#define __IMPORTNAME(_Name) _imp__##_Name +#else +#define __SYMBOL(_Name) #_Name +#define __IMPORTSYMBOL(_Name) "__imp_"#_Name +#define __IMPORTNAME(_Name) __imp_##_Name +#endif +#ifdef _MSC_VER +#define __CREATE_NTOS_DATA_IMPORT_ALIAS(_Name) \ + __pragma(comment(linker, "/alternatename:"__SYMBOL(_Name) "=" __IMPORTSYMBOL(_Name))) +#else /* !_MSC_VER */ +#ifndef __STRINGIFY +#define __STRINGIFY(_exp) #_exp +#endif +#define _Pragma_redifine_extname(_Name, _Target) _Pragma(__STRINGIFY(redefine_extname _Name _Target)) +#define __CREATE_NTOS_DATA_IMPORT_ALIAS(_Name) \ + _Pragma_redifine_extname(_Name,__IMPORTNAME(_Name)) #endif #if defined(_WIN64) @@ -599,11 +628,19 @@ PCONTEXT ContextRecord; } EXCEPTION_POINTERS, *PEXCEPTION_POINTERS; -/* MS definition is broken! */ -extern BOOLEAN NTSYSAPI NlsMbCodePageTag; -extern BOOLEAN NTSYSAPI NlsMbOemCodePageTag; +#ifdef _NTSYSTEM_ +extern BOOLEAN NlsMbCodePageTag; #define NLS_MB_CODE_PAGE_TAG NlsMbCodePageTag +extern BOOLEAN NlsMbOemCodePageTag; #define NLS_MB_OEM_CODE_PAGE_TAG NlsMbOemCodePageTag +#else +extern BOOLEAN *NlsMbCodePageTag; +__CREATE_NTOS_DATA_IMPORT_ALIAS(NlsMbCodePageTag) +#define NLS_MB_CODE_PAGE_TAG (*NlsMbCodePageTag) +extern BOOLEAN *NlsMbOemCodePageTag; +__CREATE_NTOS_DATA_IMPORT_ALIAS(NlsMbOemCodePageTag) +#define NLS_MB_OEM_CODE_PAGE_TAG (*NlsMbOemCodePageTag) +#endif #define SHORT_LEAST_SIGNIFICANT_BIT 0 #define SHORT_MOST_SIGNIFICANT_BIT 1 @@ -1673,6 +1710,7 @@ extern NTSYSAPI CCHAR KeNumberProcessors; #else extern PCCHAR KeNumberProcessors; +__CREATE_NTOS_DATA_IMPORT_ALIAS(KeNumberProcessors) #endif @@ -1824,8 +1862,11 @@ MmLargeSystem } MM_SYSTEMSIZE; -extern NTKERNELAPI BOOLEAN Mm64BitPhysicalAddress; -extern PVOID MmBadPointer; +#ifndef _NTSYSTEM_ +extern PBOOLEAN Mm64BitPhysicalAddress; +__CREATE_NTOS_DATA_IMPORT_ALIAS(Mm64BitPhysicalAddress) +#endif +extern NTKERNELAPI PVOID MmBadPointer; /****************************************************************************** @@ -2098,7 +2139,7 @@ /* Global debug flag */ #if DEVL -extern ULONG NtGlobalFlag; +extern NTKERNELAPI ULONG NtGlobalFlag; #define IF_NTOS_DEBUG(FlagName) if (NtGlobalFlag & (FLG_##FlagName)) #else #define IF_NTOS_DEBUG(FlagName) if(FALSE) @@ -7857,6 +7898,7 @@ } OBJECT_NAME_INFORMATION, *POBJECT_NAME_INFORMATION; /* Exported object types */ +#ifdef _NTSYSTEM_ extern POBJECT_TYPE NTSYSAPI CmKeyObjectType; extern POBJECT_TYPE NTSYSAPI ExEventObjectType; extern POBJECT_TYPE NTSYSAPI ExSemaphoreObjectType; @@ -7864,6 +7906,30 @@ extern POBJECT_TYPE NTSYSAPI PsThreadType; extern POBJECT_TYPE NTSYSAPI SeTokenObjectType; extern POBJECT_TYPE NTSYSAPI PsProcessType; +#else +extern POBJECT_TYPE *CmKeyObjectType; +extern POBJECT_TYPE *IoFileObjectType; +extern POBJECT_TYPE *ExEventObjectType; +extern POBJECT_TYPE *ExSemaphoreObjectType; +extern POBJECT_TYPE *TmTransactionManagerObjectType; +extern POBJECT_TYPE *TmResourceManagerObjectType; +extern POBJECT_TYPE *TmEnlistmentObjectType; +extern POBJECT_TYPE *TmTransactionObjectType; +extern POBJECT_TYPE *PsProcessType; +extern POBJECT_TYPE *PsThreadType; +extern POBJECT_TYPE *SeTokenObjectType; +__CREATE_NTOS_DATA_IMPORT_ALIAS(CmKeyObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(IoFileObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(ExEventObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(ExSemaphoreObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(TmTransactionManagerObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(TmResourceManagerObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(TmEnlistmentObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(TmTransactionObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(PsProcessType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(PsThreadType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(SeTokenObjectType) +#endif /****************************************************************************** @@ -8339,7 +8405,7 @@ #define HIGH_LEVEL 15 #define KI_USER_SHARED_DATA ((ULONG_PTR)(KADDRESS_BASE + 0xFFFE0000)) -extern volatile LARGE_INTEGER KeTickCount; +extern NTKERNELAPI volatile LARGE_INTEGER KeTickCount; #define PAUSE_PROCESSOR __yield(); @@ -15770,27 +15836,18 @@ #endif /* !DBG */ -#if defined(__GNUC__) - -extern NTKERNELAPI BOOLEAN KdDebuggerNotPresent; -extern NTKERNELAPI BOOLEAN KdDebuggerEnabled; -#define KD_DEBUGGER_ENABLED KdDebuggerEnabled -#define KD_DEBUGGER_NOT_PRESENT KdDebuggerNotPresent - -#elif defined(_NTDDK_) || defined(_NTIFS_) || defined(_NTHAL_) || defined(_WDMDDK_) || defined(_NTOSP_) - -extern NTKERNELAPI PBOOLEAN KdDebuggerNotPresent; -extern NTKERNELAPI PBOOLEAN KdDebuggerEnabled; -#define KD_DEBUGGER_ENABLED *KdDebuggerEnabled -#define KD_DEBUGGER_NOT_PRESENT *KdDebuggerNotPresent - -#else - -extern BOOLEAN KdDebuggerNotPresent; +#ifdef _NTSYSTEM_ extern BOOLEAN KdDebuggerEnabled; #define KD_DEBUGGER_ENABLED KdDebuggerEnabled +extern BOOLEAN KdDebuggerNotPresent; #define KD_DEBUGGER_NOT_PRESENT KdDebuggerNotPresent - +#else +extern BOOLEAN *KdDebuggerEnabled; +__CREATE_NTOS_DATA_IMPORT_ALIAS(KdDebuggerEnabled) +#define KD_DEBUGGER_ENABLED (*KdDebuggerEnabled) +extern BOOLEAN *KdDebuggerNotPresent; +__CREATE_NTOS_DATA_IMPORT_ALIAS(KdDebuggerNotPresent) +#define KD_DEBUGGER_NOT_PRESENT (*KdDebuggerNotPresent) #endif #if (NTDDI_VERSION >= NTDDI_WIN2K) Modified: trunk/reactos/include/reactos/libs/pseh/pseh3.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/reactos/libs/pseh/…
============================================================================== --- trunk/reactos/include/reactos/libs/pseh/pseh3.h [iso-8859-1] (original) +++ trunk/reactos/include/reactos/libs/pseh/pseh3.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -120,7 +120,7 @@ #define _SEH3$_EnforceFramePointer() asm volatile ("#\n" : : "m"(*(char*)__builtin_alloca(4)) : "%esp", "memory") /* CLANG doesn't have asm goto! */ -#define _SEH3$_ASM_GOTO(_Label, ...) +#define _SEH3$_ASM_GOTO(...) int __attribute__((regparm(3))) @@ -167,7 +167,7 @@ /* This will make GCC use ebp, even if it was disabled by -fomit-frame-pointer */ #define _SEH3$_EnforceFramePointer() asm volatile ("#\n" : : "m"(*(char*)__builtin_alloca(0)) : "%esp", "memory") -#define _SEH3$_ASM_GOTO(_Label, ...) asm goto ("#\n" : : : "memory", ## __VA_ARGS__ : _Label) +#define _SEH3$_ASM_GOTO(...) asm goto ("#\n" : : : "memory" : __VA_ARGS__) #ifdef __cplusplus #define _SEH3$_CALL_WRAPPER(_Function, _TrylevelFrame, _DataTable) \ @@ -177,7 +177,7 @@ : \ : "m" (*(_TrylevelFrame)), "m" (*(_DataTable)), "c"(__builtin_alloca(0)) \ : "eax", "edx", "memory" \ - : _SEH3$_l_HandlerTarget, _SEH3$_l_FilterOrFinally) + : _SEH3$_l_BeforeTry, _SEH3$_l_HandlerTarget, _SEH3$_l_OnException, _SEH3$_l_BeforeFilterOrFinally, _SEH3$_l_FilterOrFinally) #else #define _SEH3$_CALL_WRAPPER(_Function, _TrylevelFrame, _DataTable) \ @@ -187,7 +187,7 @@ : \ : "m" (*(_TrylevelFrame)), "m" (*(_DataTable)) \ : "eax", "edx", "ecx", "memory" \ - : _SEH3$_l_HandlerTarget) + : _SEH3$_l_BeforeTry, _SEH3$_l_HandlerTarget, _SEH3$_l_OnException, _SEH3$_l_BeforeFilterOrFinally, _SEH3$_l_FilterOrFinally) #endif /* This is an asm wrapper around _SEH3$_RegisterFrame */ @@ -202,10 +202,8 @@ around into places that are never executed. */ #define _SEH3$_SCARE_GCC() \ void *plabel; \ - _SEH3$_ASM_GOTO(_SEH3$_l_BeforeTry); \ - _SEH3$_ASM_GOTO(_SEH3$_l_HandlerTarget); \ - _SEH3$_ASM_GOTO(_SEH3$_l_OnException); \ - asm volatile ("#" : "=a"(plabel) : "p"(&&_SEH3$_l_BeforeTry), "p"(&&_SEH3$_l_HandlerTarget), "p"(&&_SEH3$_l_OnException) \ + _SEH3$_ASM_GOTO(_SEH3$_l_BeforeTry, _SEH3$_l_HandlerTarget, _SEH3$_l_OnException, _SEH3$_l_BeforeFilterOrFinally, _SEH3$_l_FilterOrFinally); \ + asm volatile ("#" : "=a"(plabel) : "p"(&&_SEH3$_l_BeforeTry), "p"(&&_SEH3$_l_HandlerTarget), "p"(&&_SEH3$_l_OnException), "p"(&&_SEH3$_l_FilterOrFinally) \ : "ebx", "ecx", "edx", "esi", "edi", "flags", "memory" ); \ goto _SEH3$_l_OnException; Modified: trunk/reactos/include/xdk/ccfuncs.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/ccfuncs.h?rev=…
============================================================================== --- trunk/reactos/include/xdk/ccfuncs.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/ccfuncs.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -6,7 +6,7 @@ (((PSECTION_OBJECT_POINTERS)(FO)->SectionObjectPointer)->SharedCacheMap != NULL) \ ) -extern ULONG CcFastMdlReadWait; +extern NTKERNELAPI ULONG CcFastMdlReadWait; #if (NTDDI_VERSION >= NTDDI_WIN2K) Modified: trunk/reactos/include/xdk/extypes.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/extypes.h?rev=…
============================================================================== --- trunk/reactos/include/xdk/extypes.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/extypes.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -271,7 +271,7 @@ /* Global debug flag */ #if DEVL -extern ULONG NtGlobalFlag; +extern NTKERNELAPI ULONG NtGlobalFlag; #define IF_NTOS_DEBUG(FlagName) if (NtGlobalFlag & (FLG_##FlagName)) #else #define IF_NTOS_DEBUG(FlagName) if(FALSE) Modified: trunk/reactos/include/xdk/fsrtlfuncs.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/fsrtlfuncs.h?r…
============================================================================== --- trunk/reactos/include/xdk/fsrtlfuncs.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/fsrtlfuncs.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -1580,26 +1580,31 @@ (InterlockedDecrement((LONG volatile *)&((FL)->LockRequestsInProgress)));\ } -/* GCC compatible definition, MS one is retarded */ -extern NTKERNELAPI const UCHAR * const FsRtlLegalAnsiCharacterArray; -#define LEGAL_ANSI_CHARACTER_ARRAY FsRtlLegalAnsiCharacterArray +#ifdef _NTSYSTEM_ +extern const UCHAR * const FsRtlLegalAnsiCharacterArray; +#define LEGAL_ANSI_CHARACTER_ARRAY FsRtlLegalAnsiCharacterArray +#else +extern const UCHAR * const *FsRtlLegalAnsiCharacterArray; +__CREATE_NTOS_DATA_IMPORT_ALIAS(FsRtlLegalAnsiCharacterArray) +#define LEGAL_ANSI_CHARACTER_ARRAY (*FsRtlLegalAnsiCharacterArray) +#endif #define FsRtlIsAnsiCharacterWild(C) ( \ - FlagOn(FsRtlLegalAnsiCharacterArray[(UCHAR)(C)], FSRTL_WILD_CHARACTER ) \ + FlagOn(LEGAL_ANSI_CHARACTER_ARRAY[(UCHAR)(C)], FSRTL_WILD_CHARACTER ) \ ) #define FsRtlIsAnsiCharacterLegalFat(C, WILD) ( \ - FlagOn(FsRtlLegalAnsiCharacterArray[(UCHAR)(C)], (FSRTL_FAT_LEGAL) | \ + FlagOn(LEGAL_ANSI_CHARACTER_ARRAY[(UCHAR)(C)], (FSRTL_FAT_LEGAL) | \ ((WILD) ? FSRTL_WILD_CHARACTER : 0 )) \ ) #define FsRtlIsAnsiCharacterLegalHpfs(C, WILD) ( \ - FlagOn(FsRtlLegalAnsiCharacterArray[(UCHAR)(C)], (FSRTL_HPFS_LEGAL) | \ + FlagOn(LEGAL_ANSI_CHARACTER_ARRAY[(UCHAR)(C)], (FSRTL_HPFS_LEGAL) | \ ((WILD) ? FSRTL_WILD_CHARACTER : 0 )) \ ) #define FsRtlIsAnsiCharacterLegalNtfs(C, WILD) ( \ - FlagOn(FsRtlLegalAnsiCharacterArray[(UCHAR)(C)], (FSRTL_NTFS_LEGAL) | \ + FlagOn(LEGAL_ANSI_CHARACTER_ARRAY[(UCHAR)(C)], (FSRTL_NTFS_LEGAL) | \ ((WILD) ? FSRTL_WILD_CHARACTER : 0 )) \ ) @@ -1627,7 +1632,7 @@ #define FsRtlIsUnicodeCharacterWild(C) ( \ (((C) >= 0x40) ? \ FALSE : \ - FlagOn(FsRtlLegalAnsiCharacterArray[(C)], FSRTL_WILD_CHARACTER )) \ + FlagOn(LEGAL_ANSI_CHARACTER_ARRAY[(C)], FSRTL_WILD_CHARACTER )) \ ) #define FsRtlInitPerFileContext( _fc, _owner, _inst, _cb) \ Modified: trunk/reactos/include/xdk/haltypes.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/haltypes.h?rev…
============================================================================== --- trunk/reactos/include/xdk/haltypes.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/haltypes.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -269,14 +269,12 @@ #endif } HAL_DISPATCH, *PHAL_DISPATCH; -/* GCC/MSVC and WDK compatible declaration */ -extern NTKERNELAPI HAL_DISPATCH HalDispatchTable; - -#if defined(_NTOSKRNL_) || defined(_BLDR_) +#ifdef _NTSYSTEM_ +extern HAL_DISPATCH HalDispatchTable; #define HALDISPATCH (&HalDispatchTable) #else -/* This is a WDK compatibility definition */ -#define HalDispatchTable (&HalDispatchTable) +extern PHAL_DISPATCH HalDispatchTable; +__CREATE_NTOS_DATA_IMPORT_ALIAS(HalDispatchTable) #define HALDISPATCH HalDispatchTable #endif Modified: trunk/reactos/include/xdk/ia64/ke.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/ia64/ke.h?rev=…
============================================================================== --- trunk/reactos/include/xdk/ia64/ke.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/ia64/ke.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -17,7 +17,7 @@ #define HIGH_LEVEL 15 #define KI_USER_SHARED_DATA ((ULONG_PTR)(KADDRESS_BASE + 0xFFFE0000)) -extern volatile LARGE_INTEGER KeTickCount; +extern NTKERNELAPI volatile LARGE_INTEGER KeTickCount; #define PAUSE_PROCESSOR __yield(); Modified: trunk/reactos/include/xdk/iotypes.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/iotypes.h?rev=…
============================================================================== --- trunk/reactos/include/xdk/iotypes.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/iotypes.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -7037,35 +7037,13 @@ _In_ BOOLEAN SafeToRecurse); #endif /* (NTDDI_VERSION >= NTDDI_VISTA) */ -#define DO_VERIFY_VOLUME 0x00000002 -#define DO_BUFFERED_IO 0x00000004 -#define DO_EXCLUSIVE 0x00000008 -#define DO_DIRECT_IO 0x00000010 -#define DO_MAP_IO_BUFFER 0x00000020 -#define DO_DEVICE_HAS_NAME 0x00000040 -#define DO_DEVICE_INITIALIZING 0x00000080 -#define DO_SYSTEM_BOOT_PARTITION 0x00000100 -#define DO_LONG_TERM_REQUESTS 0x00000200 -#define DO_NEVER_LAST_DEVICE 0x00000400 -#define DO_SHUTDOWN_REGISTERED 0x00000800 -#define DO_BUS_ENUMERATED_DEVICE 0x00001000 -#define DO_POWER_PAGABLE 0x00002000 -#define DO_POWER_INRUSH 0x00004000 -#define DO_LOW_PRIORITY_FILESYSTEM 0x00010000 -#define DO_SUPPORTS_TRANSACTIONS 0x00040000 -#define DO_FORCE_NEITHER_IO 0x00080000 -#define DO_VOLUME_DEVICE_OBJECT 0x00100000 -#define DO_SYSTEM_SYSTEM_PARTITION 0x00200000 -#define DO_SYSTEM_CRITICAL_PARTITION 0x00400000 -#define DO_DISALLOW_EXECUTE 0x00800000 - -extern KSPIN_LOCK IoStatisticsLock; -extern ULONG IoReadOperationCount; -extern ULONG IoWriteOperationCount; -extern ULONG IoOtherOperationCount; -extern LARGE_INTEGER IoReadTransferCount; -extern LARGE_INTEGER IoWriteTransferCount; -extern LARGE_INTEGER IoOtherTransferCount; +extern NTKERNELAPI KSPIN_LOCK IoStatisticsLock; +extern NTKERNELAPI ULONG IoReadOperationCount; +extern NTKERNELAPI ULONG IoWriteOperationCount; +extern NTKERNELAPI ULONG IoOtherOperationCount; +extern NTKERNELAPI LARGE_INTEGER IoReadTransferCount; +extern NTKERNELAPI LARGE_INTEGER IoWriteTransferCount; +extern NTKERNELAPI LARGE_INTEGER IoOtherTransferCount; #define IO_FILE_OBJECT_NON_PAGED_POOL_CHARGE 64 #define IO_FILE_OBJECT_PAGED_POOL_CHARGE 1024 Modified: trunk/reactos/include/xdk/kdfuncs.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/kdfuncs.h?rev=…
============================================================================== --- trunk/reactos/include/xdk/kdfuncs.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/kdfuncs.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -119,27 +119,18 @@ #endif /* !DBG */ -#if defined(__GNUC__) - -extern NTKERNELAPI BOOLEAN KdDebuggerNotPresent; -extern NTKERNELAPI BOOLEAN KdDebuggerEnabled; -#define KD_DEBUGGER_ENABLED KdDebuggerEnabled -#define KD_DEBUGGER_NOT_PRESENT KdDebuggerNotPresent - -#elif defined(_NTDDK_) || defined(_NTIFS_) || defined(_NTHAL_) || defined(_WDMDDK_) || defined(_NTOSP_) - -extern NTKERNELAPI PBOOLEAN KdDebuggerNotPresent; -extern NTKERNELAPI PBOOLEAN KdDebuggerEnabled; -#define KD_DEBUGGER_ENABLED *KdDebuggerEnabled -#define KD_DEBUGGER_NOT_PRESENT *KdDebuggerNotPresent - -#else - -extern BOOLEAN KdDebuggerNotPresent; +#ifdef _NTSYSTEM_ extern BOOLEAN KdDebuggerEnabled; #define KD_DEBUGGER_ENABLED KdDebuggerEnabled +extern BOOLEAN KdDebuggerNotPresent; #define KD_DEBUGGER_NOT_PRESENT KdDebuggerNotPresent - +#else +extern BOOLEAN *KdDebuggerEnabled; +__CREATE_NTOS_DATA_IMPORT_ALIAS(KdDebuggerEnabled) +#define KD_DEBUGGER_ENABLED (*KdDebuggerEnabled) +extern BOOLEAN *KdDebuggerNotPresent; +__CREATE_NTOS_DATA_IMPORT_ALIAS(KdDebuggerNotPresent) +#define KD_DEBUGGER_NOT_PRESENT (*KdDebuggerNotPresent) #endif #if (NTDDI_VERSION >= NTDDI_WIN2K) Modified: trunk/reactos/include/xdk/ketypes.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/ketypes.h?rev=…
============================================================================== --- trunk/reactos/include/xdk/ketypes.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/ketypes.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -987,6 +987,7 @@ extern NTSYSAPI CCHAR KeNumberProcessors; #else extern PCCHAR KeNumberProcessors; +__CREATE_NTOS_DATA_IMPORT_ALIAS(KeNumberProcessors) #endif $endif (_WDMDDK_) Modified: trunk/reactos/include/xdk/mmtypes.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/mmtypes.h?rev=…
============================================================================== --- trunk/reactos/include/xdk/mmtypes.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/mmtypes.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -147,8 +147,11 @@ MmLargeSystem } MM_SYSTEMSIZE; -extern NTKERNELAPI BOOLEAN Mm64BitPhysicalAddress; -extern PVOID MmBadPointer; +#ifndef _NTSYSTEM_ +extern PBOOLEAN Mm64BitPhysicalAddress; +__CREATE_NTOS_DATA_IMPORT_ALIAS(Mm64BitPhysicalAddress) +#endif +extern NTKERNELAPI PVOID MmBadPointer; $endif (_WDMDDK_) $if (_NTDDK_) Modified: trunk/reactos/include/xdk/ntifs.template.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/ntifs.template…
============================================================================== --- trunk/reactos/include/xdk/ntifs.template.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/ntifs.template.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -1124,13 +1124,14 @@ #define HalGetDmaAlignmentRequirement() 1L #endif -extern NTKERNELAPI PUSHORT NlsOemLeadByteInfo; -#define NLS_OEM_LEAD_BYTE_INFO NlsOemLeadByteInfo - -#ifdef NLS_MB_CODE_PAGE_TAG -#undef NLS_MB_CODE_PAGE_TAG -#endif -#define NLS_MB_CODE_PAGE_TAG NlsMbOemCodePageTag +#ifdef _NTSYSTEM_ +extern PUSHORT NlsOemLeadByteInfo; +#define NLS_OEM_LEAD_BYTE_INFO NlsOemLeadByteInfo +#else +extern PUSHORT *NlsOemLeadByteInfo; +__CREATE_NTOS_DATA_IMPORT_ALIAS(NlsOemLeadByteInfo) +#define NLS_OEM_LEAD_BYTE_INFO (*NlsOemLeadByteInfo) +#endif #if (NTDDI_VERSION >= NTDDI_VISTA) Modified: trunk/reactos/include/xdk/obtypes.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/obtypes.h?rev=…
============================================================================== --- trunk/reactos/include/xdk/obtypes.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/obtypes.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -125,6 +125,7 @@ } OBJECT_NAME_INFORMATION, *POBJECT_NAME_INFORMATION; /* Exported object types */ +#ifdef _NTSYSTEM_ extern POBJECT_TYPE NTSYSAPI CmKeyObjectType; extern POBJECT_TYPE NTSYSAPI ExEventObjectType; extern POBJECT_TYPE NTSYSAPI ExSemaphoreObjectType; @@ -132,6 +133,30 @@ extern POBJECT_TYPE NTSYSAPI PsThreadType; extern POBJECT_TYPE NTSYSAPI SeTokenObjectType; extern POBJECT_TYPE NTSYSAPI PsProcessType; +#else +extern POBJECT_TYPE *CmKeyObjectType; +extern POBJECT_TYPE *IoFileObjectType; +extern POBJECT_TYPE *ExEventObjectType; +extern POBJECT_TYPE *ExSemaphoreObjectType; +extern POBJECT_TYPE *TmTransactionManagerObjectType; +extern POBJECT_TYPE *TmResourceManagerObjectType; +extern POBJECT_TYPE *TmEnlistmentObjectType; +extern POBJECT_TYPE *TmTransactionObjectType; +extern POBJECT_TYPE *PsProcessType; +extern POBJECT_TYPE *PsThreadType; +extern POBJECT_TYPE *SeTokenObjectType; +__CREATE_NTOS_DATA_IMPORT_ALIAS(CmKeyObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(IoFileObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(ExEventObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(ExSemaphoreObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(TmTransactionManagerObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(TmResourceManagerObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(TmEnlistmentObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(TmTransactionObjectType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(PsProcessType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(PsThreadType) +__CREATE_NTOS_DATA_IMPORT_ALIAS(SeTokenObjectType) +#endif $endif (_WDMDDK_) $if (_NTIFS_) Modified: trunk/reactos/include/xdk/rtltypes.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/rtltypes.h?rev…
============================================================================== --- trunk/reactos/include/xdk/rtltypes.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/rtltypes.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -197,11 +197,19 @@ PCONTEXT ContextRecord; } EXCEPTION_POINTERS, *PEXCEPTION_POINTERS; -/* MS definition is broken! */ -extern BOOLEAN NTSYSAPI NlsMbCodePageTag; -extern BOOLEAN NTSYSAPI NlsMbOemCodePageTag; +#ifdef _NTSYSTEM_ +extern BOOLEAN NlsMbCodePageTag; #define NLS_MB_CODE_PAGE_TAG NlsMbCodePageTag +extern BOOLEAN NlsMbOemCodePageTag; #define NLS_MB_OEM_CODE_PAGE_TAG NlsMbOemCodePageTag +#else +extern BOOLEAN *NlsMbCodePageTag; +__CREATE_NTOS_DATA_IMPORT_ALIAS(NlsMbCodePageTag) +#define NLS_MB_CODE_PAGE_TAG (*NlsMbCodePageTag) +extern BOOLEAN *NlsMbOemCodePageTag; +__CREATE_NTOS_DATA_IMPORT_ALIAS(NlsMbOemCodePageTag) +#define NLS_MB_OEM_CODE_PAGE_TAG (*NlsMbOemCodePageTag) +#endif #define SHORT_LEAST_SIGNIFICANT_BIT 0 #define SHORT_MOST_SIGNIFICANT_BIT 1 @@ -551,11 +559,11 @@ (NTAPI *PRTL_FREE_STRING_ROUTINE)( _In_ __drv_freesMem(Mem) _Post_invalid_ PVOID Buffer); -extern const PRTL_ALLOCATE_STRING_ROUTINE RtlAllocateStringRoutine; -extern const PRTL_FREE_STRING_ROUTINE RtlFreeStringRoutine; +extern NTKERNELAPI const PRTL_ALLOCATE_STRING_ROUTINE RtlAllocateStringRoutine; +extern NTKERNELAPI const PRTL_FREE_STRING_ROUTINE RtlFreeStringRoutine; #if _WIN32_WINNT >= 0x0600 -extern const PRTL_REALLOCATE_STRING_ROUTINE RtlReallocateStringRoutine; +extern NTKERNELAPI const PRTL_REALLOCATE_STRING_ROUTINE RtlReallocateStringRoutine; #endif _Function_class_(RTL_HEAP_COMMIT_ROUTINE) Modified: trunk/reactos/include/xdk/sefuncs.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/sefuncs.h?rev=…
============================================================================== --- trunk/reactos/include/xdk/sefuncs.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/sefuncs.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -588,4 +588,5 @@ ((PSECURITY_SUBJECT_CONTEXT) SubjectContext)->PrimaryToken ) extern NTKERNELAPI PSE_EXPORTS SeExports; + $endif (_NTIFS_) Modified: trunk/reactos/include/xdk/wdm.template.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/include/xdk/wdm.template.h…
============================================================================== --- trunk/reactos/include/xdk/wdm.template.h [iso-8859-1] (original) +++ trunk/reactos/include/xdk/wdm.template.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -82,10 +82,13 @@ #endif /* For ReactOS */ -#if !defined(_NTOSKRNL_) && !defined(_BLDR_) +#if !defined(_NTOSKRNL_) && !defined(_BLDR_) && !defined(_NTSYSTEM_) #define NTKERNELAPI DECLSPEC_IMPORT #else #define NTKERNELAPI +#ifndef _NTSYSTEM_ +#define _NTSYSTEM_ +#endif #endif #if defined(_X86_) && !defined(_NTHAL_) @@ -129,6 +132,29 @@ #define ALLOC_DATA_PRAGMA 1 #endif +#endif /* _MSC_VER */ + +/* These macros are used to create aliases for imported data. We need to do + this to have declarations that are compatible with MS DDK */ +#ifdef _M_IX86 +#define __SYMBOL(_Name) "_"#_Name +#define __IMPORTSYMBOL(_Name) "__imp__"#_Name +#define __IMPORTNAME(_Name) _imp__##_Name +#else +#define __SYMBOL(_Name) #_Name +#define __IMPORTSYMBOL(_Name) "__imp_"#_Name +#define __IMPORTNAME(_Name) __imp_##_Name +#endif +#ifdef _MSC_VER +#define __CREATE_NTOS_DATA_IMPORT_ALIAS(_Name) \ + __pragma(comment(linker, "/alternatename:"__SYMBOL(_Name) "=" __IMPORTSYMBOL(_Name))) +#else /* !_MSC_VER */ +#ifndef __STRINGIFY +#define __STRINGIFY(_exp) #_exp +#endif +#define _Pragma_redifine_extname(_Name, _Target) _Pragma(__STRINGIFY(redefine_extname _Name _Target)) +#define __CREATE_NTOS_DATA_IMPORT_ALIAS(_Name) \ + _Pragma_redifine_extname(_Name,__IMPORTNAME(_Name)) #endif #if defined(_WIN64) Modified: trunk/reactos/lib/rtl/nls.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/rtl/nls.c?rev=63247&r1…
============================================================================== --- trunk/reactos/lib/rtl/nls.c [iso-8859-1] (original) +++ trunk/reactos/lib/rtl/nls.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -31,13 +31,12 @@ PWCHAR NlsOemToUnicodeTable = NULL; PCHAR NlsUnicodeToOemTable =NULL; PWCHAR NlsDbcsUnicodeToOemTable = NULL; -PUSHORT _NlsOemLeadByteInfo = NULL; /* exported */ +PUSHORT NlsOemLeadByteInfo = NULL; /* exported */ USHORT NlsOemDefaultChar = '\0'; USHORT NlsUnicodeDefaultChar = 0; -#define NlsOemLeadByteInfo _NlsOemLeadByteInfo #define INIT_FUNCTION /* FUNCTIONS *****************************************************************/ Modified: trunk/reactos/ntoskrnl/ex/event.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ex/event.c?rev=63…
============================================================================== --- trunk/reactos/ntoskrnl/ex/event.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/ex/event.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -19,7 +19,7 @@ /* GLOBALS *******************************************************************/ -POBJECT_TYPE _ExEventObjectType = NULL; +POBJECT_TYPE ExEventObjectType = NULL; GENERIC_MAPPING ExpEventMapping = { Modified: trunk/reactos/ntoskrnl/ex/sem.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ex/sem.c?rev=6324…
============================================================================== --- trunk/reactos/ntoskrnl/ex/sem.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/ex/sem.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -19,7 +19,7 @@ /* GLOBALS ******************************************************************/ -POBJECT_TYPE _ExSemaphoreObjectType; +POBJECT_TYPE ExSemaphoreObjectType; GENERIC_MAPPING ExSemaphoreMapping = { Modified: trunk/reactos/ntoskrnl/fsrtl/fsrtlpc.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/fsrtl/fsrtlpc.c?r…
============================================================================== --- trunk/reactos/ntoskrnl/fsrtl/fsrtlpc.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/fsrtl/fsrtlpc.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -18,7 +18,7 @@ ULONG FsRtlPagingIoResourceSelector; NTSTATUS NTAPI INIT_FUNCTION FsRtlInitializeWorkerThread(VOID); -static UCHAR LegalAnsiCharacterArray[] = +static const UCHAR LegalAnsiCharacterArray[] = { 0, /* CTRL+@, 0x00 */ 0, /* CTRL+A, 0x01 */ @@ -150,7 +150,7 @@ FSRTL_FAT_LEGAL | FSRTL_HPFS_LEGAL | FSRTL_NTFS_LEGAL /* 0x7f */ }; -PUCHAR FsRtlLegalAnsiCharacterArray = LegalAnsiCharacterArray; +const UCHAR * const FsRtlLegalAnsiCharacterArray = LegalAnsiCharacterArray; /* PRIVATE FUNCTIONS *********************************************************/ Modified: trunk/reactos/ntoskrnl/include/internal/fsrtl.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/include/internal/…
============================================================================== --- trunk/reactos/ntoskrnl/include/internal/fsrtl.h [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/include/internal/fsrtl.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -133,5 +133,4 @@ // Global data inside the File System Runtime Library // extern PERESOURCE FsRtlPagingIoResources; -extern PUCHAR _FsRtlLegalAnsiCharacterArray; extern PAGED_LOOKASIDE_LIST FsRtlFileLockLookasideList; Modified: trunk/reactos/ntoskrnl/include/internal/kd.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/include/internal/…
============================================================================== --- trunk/reactos/ntoskrnl/include/internal/kd.h [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/include/internal/kd.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -1,19 +1,12 @@ #pragma once #include <cportlib/cportlib.h> - -#ifdef _M_PPC -#define KdDebuggerEnabled _KdDebuggerEnabled -#define KdDebuggerNotPresent _KdDebuggerNotPresent -#endif // // Kernel Debugger Port Definition // struct _KD_DISPATCH_TABLE; extern CPPORT GdbPortInfo; -extern BOOLEAN _KdDebuggerEnabled; -extern BOOLEAN _KdDebuggerNotPresent; extern BOOLEAN KdBreakAfterSymbolLoad; extern BOOLEAN KdPitchDebugger; extern BOOLEAN KdIgnoreUmExceptions; Modified: trunk/reactos/ntoskrnl/include/internal/kd64.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/include/internal/…
============================================================================== --- trunk/reactos/ntoskrnl/include/internal/kd64.h [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/include/internal/kd64.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -494,8 +494,6 @@ extern PKDEBUG_SWITCH_ROUTINE KiDebugSwitchRoutine; extern BOOLEAN KdBreakAfterSymbolLoad; extern BOOLEAN KdPitchDebugger; -extern BOOLEAN _KdDebuggerNotPresent; -extern BOOLEAN _KdDebuggerEnabled; extern BOOLEAN KdAutoEnableOnEvent; extern BOOLEAN KdBlockEnable; extern BOOLEAN KdIgnoreUmExceptions; Modified: trunk/reactos/ntoskrnl/include/ntoskrnl.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/include/ntoskrnl.…
============================================================================== --- trunk/reactos/ntoskrnl/include/ntoskrnl.h [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/include/ntoskrnl.h [iso-8859-1] Sun May 11 23:11:16 2014 @@ -90,31 +90,8 @@ // // Define the internal versions of external and public global data // -#define IoFileObjectType _IoFileObjectType -#define PsThreadType _PsThreadType -#define PsProcessType _PsProcessType -#define ExEventObjectType _ExEventObjectType -#define ExSemaphoreObjectType _ExSemaphoreObjectType -#define KdDebuggerEnabled _KdDebuggerEnabled -#define KdDebuggerNotPresent _KdDebuggerNotPresent -#define NlsOemLeadByteInfo _NlsOemLeadByteInfo -extern PUSHORT _NlsOemLeadByteInfo; #define KeNumberProcessors _KeNumberProcessors extern UCHAR _KeNumberProcessors; -#define FsRtlLegalAnsiCharacterArray _FsRtlLegalAnsiCharacterArray -#undef LEGAL_ANSI_CHARACTER_ARRAY -#undef NLS_MB_CODE_PAGE_TAG -#undef NLS_OEM_LEAD_BYTE_INFO -#define LEGAL_ANSI_CHARACTER_ARRAY FsRtlLegalAnsiCharacterArray -#define NLS_MB_CODE_PAGE_TAG NlsMbOemCodePageTag -#define NLS_OEM_LEAD_BYTE_INFO _NlsOemLeadByteInfo -#undef KD_DEBUGGER_ENABLED -#undef KD_DEBUGGER_NOT_PRESENT -#define KD_DEBUGGER_ENABLED KdDebuggerEnabled -#define KD_DEBUGGER_NOT_PRESENT KdDebuggerNotPresent -#define HalDispatchTable _HalDispatchTable -#undef HALDISPATCH -#define HALDISPATCH (&HalDispatchTable) #define ExRaiseStatus RtlRaiseStatus /* Internal Headers */ Modified: trunk/reactos/ntoskrnl/kd64/kdapi.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/kd64/kdapi.c?rev=…
============================================================================== --- trunk/reactos/ntoskrnl/kd64/kdapi.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/kd64/kdapi.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -1903,9 +1903,7 @@ /* We are disabled now */ KdDebuggerEnabled = FALSE; -#undef KdDebuggerEnabled SharedUserData->KdDebuggerEnabled = FALSE; -#define KdDebuggerEnabled _KdDebuggerEnabled } } Modified: trunk/reactos/ntoskrnl/kd64/kddata.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/kd64/kddata.c?rev…
============================================================================== --- trunk/reactos/ntoskrnl/kd64/kddata.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/kd64/kddata.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -79,8 +79,8 @@ // BOOLEAN KdBreakAfterSymbolLoad; BOOLEAN KdPitchDebugger; -BOOLEAN _KdDebuggerNotPresent; -BOOLEAN _KdDebuggerEnabled; +BOOLEAN KdDebuggerNotPresent; +BOOLEAN KdDebuggerEnabled; BOOLEAN KdAutoEnableOnEvent; BOOLEAN KdBlockEnable; BOOLEAN KdIgnoreUmExceptions; Modified: trunk/reactos/ntoskrnl/kd64/kdinit.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/kd64/kdinit.c?rev…
============================================================================== --- trunk/reactos/ntoskrnl/kd64/kdinit.c [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/kd64/kdinit.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -310,9 +310,7 @@ KdDebuggerEnabled = TRUE; /* Let user-mode know that it's enabled as well */ -#undef KdDebuggerEnabled SharedUserData->KdDebuggerEnabled = TRUE; -#define KdDebuggerEnabled _KdDebuggerEnabled /* Check if the debugger should be disabled initially */ if (DisableKdAfterInit) Modified: trunk/reactos/ntoskrnl/ntoskrnl.spec URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/ntoskrnl/ntoskrnl.spec?rev…
============================================================================== --- trunk/reactos/ntoskrnl/ntoskrnl.spec [iso-8859-1] (original) +++ trunk/reactos/ntoskrnl/ntoskrnl.spec [iso-8859-1] Sun May 11 23:11:16 2014 @@ -82,7 +82,7 @@ @ stdcall ExEnterCriticalRegionAndAcquireResourceShared(ptr) @ stdcall ExEnterCriticalRegionAndAcquireSharedWaitForExclusive(ptr) @ stdcall ExEnumHandleTable(ptr ptr ptr ptr) -@ extern ExEventObjectType _ExEventObjectType +@ extern ExEventObjectType @ stdcall ExExtendZone(ptr ptr long) @ stdcall ExFreeCacheAwareRundownProtection(ptr) @ stdcall ExFreePool(ptr) @@ -144,7 +144,7 @@ @ fastcall ExReleaseRundownProtectionEx(ptr long) ExfReleaseRundownProtectionEx @ fastcall ExRundownCompleted(ptr) ExfRundownCompleted @ fastcall ExRundownCompletedCacheAware(ptr) ExfRundownCompletedCacheAware -@ extern ExSemaphoreObjectType _ExSemaphoreObjectType +@ extern ExSemaphoreObjectType @ stdcall ExSetResourceOwnerPointer(ptr ptr) @ stdcall ExSetTimerResolution(long long) @ stdcall ExSizeOfRundownProtectionCacheAware() @@ -241,7 +241,7 @@ @ stdcall FsRtlIsNtstatusExpected(long) @ stdcall FsRtlIsPagingFile(ptr) @ stdcall FsRtlIsTotalDeviceFailure(ptr) -@ extern FsRtlLegalAnsiCharacterArray _FsRtlLegalAnsiCharacterArray +@ extern FsRtlLegalAnsiCharacterArray @ stdcall FsRtlLookupBaseMcbEntry(ptr long long ptr ptr ptr ptr ptr) @ stdcall FsRtlLookupLargeMcbEntry(ptr long long ptr ptr ptr ptr ptr) @ stdcall FsRtlLookupLastBaseMcbEntry(ptr ptr ptr) @@ -302,7 +302,7 @@ @ stdcall FsRtlUninitializeLargeMcb(ptr) @ stdcall FsRtlUninitializeMcb(ptr) @ stdcall FsRtlUninitializeOplock(ptr) -@ extern HalDispatchTable _HalDispatchTable +@ extern HalDispatchTable @ fastcall HalExamineMBR(ptr long long ptr) @ extern HalPrivateDispatchTable @ stdcall HeadlessDispatch(long ptr long ptr ptr) @@ -393,7 +393,7 @@ @ stdcall IoEnumerateDeviceObjectList(ptr ptr long ptr) @ stdcall IoEnumerateRegisteredFiltersList(ptr long ptr) @ stdcall IoFastQueryNetworkAttributes(ptr long long ptr ptr) -@ extern IoFileObjectType _IoFileObjectType +@ extern IoFileObjectType @ stdcall IoForwardAndCatchIrp(ptr ptr) IoForwardIrpSynchronously @ stdcall IoForwardIrpSynchronously(ptr ptr) @ stdcall IoFreeController(ptr) @@ -533,8 +533,8 @@ @ fastcall IofCallDriver(ptr ptr) @ fastcall IofCompleteRequest(ptr long) @ stdcall KdChangeOption(long long ptr long ptr ptr) -@ extern KdDebuggerEnabled _KdDebuggerEnabled -@ extern KdDebuggerNotPresent _KdDebuggerNotPresent +@ extern KdDebuggerEnabled +@ extern KdDebuggerNotPresent @ stdcall KdDisableDebugger() @ stdcall KdEnableDebugger() @ extern KdEnteredDebugger @@ -830,7 +830,7 @@ @ extern NlsMbCodePageTag @ extern NlsMbOemCodePageTag @ extern NlsOemCodePage -@ extern NlsOemLeadByteInfo _NlsOemLeadByteInfo +@ extern NlsOemLeadByteInfo @ stdcall NtAddAtom(wstr long ptr) @ stdcall NtAdjustPrivilegesToken(ptr long ptr long ptr ptr) @ stdcall -arch=i386,arm NtAlertThread(ptr) @@ -1011,7 +1011,7 @@ @ stdcall PsLookupProcessByProcessId(ptr ptr) @ stdcall PsLookupProcessThreadByCid(ptr ptr ptr) @ stdcall PsLookupThreadByThreadId(ptr ptr) -@ extern PsProcessType _PsProcessType +@ extern PsProcessType @ stdcall PsReferenceImpersonationToken(ptr ptr ptr ptr) @ stdcall PsReferencePrimaryToken(ptr) @ stdcall PsRemoveCreateThreadNotifyRoutine(ptr) @@ -1036,7 +1036,7 @@ @ stdcall PsSetThreadHardErrorsAreDisabled(ptr long) @ stdcall PsSetThreadWin32Thread(ptr ptr ptr) @ stdcall PsTerminateSystemThread(long) -@ extern PsThreadType _PsThreadType +@ extern PsThreadType ;PsWrapApcWow64Thread @ stdcall -arch=i386,arm READ_REGISTER_BUFFER_UCHAR(ptr ptr long) @ stdcall -arch=i386,arm READ_REGISTER_BUFFER_ULONG(ptr ptr long) Modified: trunk/reactos/tools/spec2def/spec2def.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/tools/spec2def/spec2def.c?…
============================================================================== --- trunk/reactos/tools/spec2def/spec2def.c [iso-8859-1] (original) +++ trunk/reactos/tools/spec2def/spec2def.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -52,7 +52,6 @@ FL_STUB = 2, FL_NONAME = 4, FL_ORDINAL = 8, - FL_DATA_ALIAS = 16 }; enum @@ -508,9 +507,7 @@ fprintf(fileDest, " PRIVATE"); } - /* Make this a data export, unless this is MSVC and -withalias was given */ - if ((pexp->nCallingConvention == CC_EXTERN) && - !(gbMSComp && (pexp->uFlags & FL_DATA_ALIAS))) + if (pexp->nCallingConvention == CC_EXTERN) { fprintf(fileDest, " DATA"); } @@ -662,15 +659,6 @@ else if (CompareToken(pc, "-stub")) { exp.uFlags |= FL_STUB; - } - else if (CompareToken(pc, "-withalias")) - { - /* This flag is to create a nin _imp_ prefixed alias for a - data export, so that the hacked DDK declarations work */ - if (exp.nCallingConvention != CC_EXTERN) - fprintf(stderr, "error: line %d -withalias on non-data export\n", nLine); - else - exp.uFlags |= FL_DATA_ALIAS; } else if (CompareToken(pc, "-norelay") || CompareToken(pc, "-register") || Modified: trunk/reactos/win32ss/gdi/eng/engevent.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/gdi/eng/engevent.c…
============================================================================== --- trunk/reactos/win32ss/gdi/eng/engevent.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/gdi/eng/engevent.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -134,7 +134,7 @@ /* Create a handle, and have Ob fill out the pKEvent field */ Status = ObReferenceObjectByHandle(EngEvent, EVENT_ALL_ACCESS, - ExEventObjectType, + *ExEventObjectType, UserMode, &EngEvent->pKEvent, NULL); Modified: trunk/reactos/win32ss/user/ntuser/main.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/user/ntuser/main.c…
============================================================================== --- trunk/reactos/win32ss/user/ntuser/main.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/user/ntuser/main.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -320,7 +320,7 @@ goto error; } Status = ObReferenceObjectByHandle(ptiCurrent->hEventQueueClient, 0, - ExEventObjectType, KernelMode, + *ExEventObjectType, KernelMode, (PVOID*)&ptiCurrent->pEventQueueServer, NULL); if (!NT_SUCCESS(Status)) { Modified: trunk/reactos/win32ss/user/ntuser/message.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/user/ntuser/messag…
============================================================================== --- trunk/reactos/win32ss/user/ntuser/message.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/user/ntuser/message.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -1548,7 +1548,7 @@ { RETURN(FALSE); } - + ptiSendTo = IntSendTo(Window, Win32Thread, Msg); if (Msg & 0x80000000 && @@ -2755,7 +2755,7 @@ ((ClientInfo->CI_flags & CI_CURTHPRHOOK) ? 1 : 0), (LPARAM)&CWP, Hook->Proc, - Hook->ihmod, + Hook->ihmod, Hook->offPfn, Hook->Ansi, &Hook->ModuleName); @@ -2774,7 +2774,7 @@ ((ClientInfo->CI_flags & CI_CURTHPRHOOK) ? 1 : 0), (LPARAM)&CWPR, Hook->Proc, - Hook->ihmod, + Hook->ihmod, Hook->offPfn, Hook->Ansi, &Hook->ModuleName); @@ -2833,7 +2833,7 @@ Status = ObReferenceObjectByHandle(hProcess, PROCESS_QUERY_INFORMATION, - PsProcessType, + *PsProcessType, UserMode, (PVOID*)&Process, NULL); Modified: trunk/reactos/win32ss/user/ntuser/misc.c URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/user/ntuser/misc.c…
============================================================================== --- trunk/reactos/win32ss/user/ntuser/misc.c [iso-8859-1] (original) +++ trunk/reactos/win32ss/user/ntuser/misc.c [iso-8859-1] Sun May 11 23:11:16 2014 @@ -223,7 +223,7 @@ break; case THREADSTATE_INSENDMESSAGE: { - PUSER_SENT_MESSAGE Message = + PUSER_SENT_MESSAGE Message = ((PTHREADINFO)PsGetCurrentThreadWin32Thread())->pusmCurrent; ERR("THREADSTATE_INSENDMESSAGE\n"); @@ -243,7 +243,7 @@ if (Message->QS_Flags & QS_SMRESULT) ret |= ISMEX_REPLIED; } - break; + break; } case THREADSTATE_GETMESSAGETIME: ret = ((PTHREADINFO)PsGetCurrentThreadWin32Thread())->timeLast; @@ -289,7 +289,7 @@ DWORD Ret = 0; // Test the only flags user can change. if (Set & ~(QF_FF10STATUS|QF_DIALOGACTIVE|QF_TABSWITCHING|QF_FMENUSTATUS|QF_FMENUSTATUSBREAK)) return 0; - if (Flags & ~(QF_FF10STATUS|QF_DIALOGACTIVE|QF_TABSWITCHING|QF_FMENUSTATUS|QF_FMENUSTATUSBREAK)) return 0; + if (Flags & ~(QF_FF10STATUS|QF_DIALOGACTIVE|QF_TABSWITCHING|QF_FMENUSTATUS|QF_FMENUSTATUSBREAK)) return 0; UserEnterExclusive(); pti = PsGetCurrentThreadWin32Thread(); if (pti->MessageQueue) @@ -448,7 +448,7 @@ Status = ObReferenceObjectByHandle(hProcess, PROCESS_QUERY_INFORMATION, - PsProcessType, + *PsProcessType, ExGetPreviousMode(), (PVOID*)&Process, NULL); @@ -656,7 +656,7 @@ ASSERT(pci->ulClientDelta == DesktopHeapGetUserDelta()); if (pti->pcti && pci->pDeskInfo) ASSERT(pci->pClientThreadInfo == (PVOID)((ULONG_PTR)pti->pcti - pci->ulClientDelta)); - if (pti->KeyboardLayout) + if (pti->KeyboardLayout) ASSERT(pci->hKL == pti->KeyboardLayout->hkl); if(pti->rpdesk != NULL) ASSERT(pti->pDeskInfo == pti->rpdesk->pDeskInfo);
10 years, 7 months
1
0
0
0
[tkreuzer] 63246: [CRT] Fix build
by tkreuzer@svn.reactos.org
Author: tkreuzer Date: Sun May 11 22:28:54 2014 New Revision: 63246 URL:
http://svn.reactos.org/svn/reactos?rev=63246&view=rev
Log: [CRT] Fix build Modified: trunk/reactos/lib/sdk/crt/string/_tsplitpath_x.h Modified: trunk/reactos/lib/sdk/crt/string/_tsplitpath_x.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/sdk/crt/string/_tsplit…
============================================================================== --- trunk/reactos/lib/sdk/crt/string/_tsplitpath_x.h [iso-8859-1] (original) +++ trunk/reactos/lib/sdk/crt/string/_tsplitpath_x.h [iso-8859-1] Sun May 11 22:28:54 2014 @@ -106,7 +106,7 @@ dir_start = path; while (*path != '\0') { -#ifndef _UNICODE +#if !defined(_UNICODE) && !defined(_LIBCNT_) /* Check for multibyte lead bytes */ if (_ismbblead((unsigned char)*path)) {
10 years, 7 months
1
0
0
0
[tkreuzer] 63245: [CRT] Fix handling of multibyte strings in _splitpath. Fixes 2 winetests.
by tkreuzer@svn.reactos.org
Author: tkreuzer Date: Sun May 11 22:25:46 2014 New Revision: 63245 URL:
http://svn.reactos.org/svn/reactos?rev=63245&view=rev
Log: [CRT] Fix handling of multibyte strings in _splitpath. Fixes 2 winetests. Modified: trunk/reactos/lib/sdk/crt/string/_tsplitpath_x.h Modified: trunk/reactos/lib/sdk/crt/string/_tsplitpath_x.h URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/lib/sdk/crt/string/_tsplit…
============================================================================== --- trunk/reactos/lib/sdk/crt/string/_tsplitpath_x.h [iso-8859-1] (original) +++ trunk/reactos/lib/sdk/crt/string/_tsplitpath_x.h [iso-8859-1] Sun May 11 22:25:46 2014 @@ -7,6 +7,7 @@ #include <precomp.h> #include <tchar.h> +#include <mbctype.h> #if IS_SECAPI #define _FAILURE -1 @@ -99,12 +100,24 @@ drive[2] = '\0'; } path += 2; - } + } /* Scan the rest of the string */ dir_start = path; while (*path != '\0') { +#ifndef _UNICODE + /* Check for multibyte lead bytes */ + if (_ismbblead((unsigned char)*path)) + { + /* Check for unexpected end of string */ + if (path[1] == 0) break; + + /* Skip the lead byte and the following byte */ + path += 2; + continue; + } +#endif /* Remember last path separator and last dot */ if ((*path == '\\') || (*path == '/')) file_start = path + 1; if (*path == '.') ext_start = path; @@ -114,14 +127,14 @@ /* Check if we got a file name / extension */ if (!file_start) file_start = dir_start; - if (!ext_start || ext_start < file_start) + if (!ext_start || (ext_start < file_start)) ext_start = path; if (dir) { src = dir_start; count = dir_size - 1; - while (src < file_start && count--) *dir++ = *src++; + while ((src < file_start) && count--) *dir++ = *src++; *dir = '\0'; }
10 years, 7 months
1
0
0
0
[spetreolle] 63244: [INF] Fix line endings (LF=> CRLF, CR)
by spetreolle@svn.reactos.org
Author: spetreolle Date: Sun May 11 20:59:17 2014 New Revision: 63244 URL:
http://svn.reactos.org/svn/reactos?rev=63244&view=rev
Log: [INF] Fix line endings (LF=> CRLF,CR) Modified: trunk/reactos/media/inf/flpydisk.inf (contents, props changed) Modified: trunk/reactos/media/inf/flpydisk.inf URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/media/inf/flpydisk.inf?rev…
============================================================================== Binary files - no diff available. Propchange: trunk/reactos/media/inf/flpydisk.inf ------------------------------------------------------------------------------ --- svn:eol-style (original) +++ svn:eol-style (removed) @@ -1 +0,0 @@ -native
10 years, 7 months
1
0
0
0
← Newer
1
...
25
26
27
28
29
30
31
...
44
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
Results per page:
10
25
50
100
200