Author: cwittich
Date: Tue Jan 20 02:19:52 2009
New Revision: 38970
URL: http://svn.reactos.org/svn/reactos?rev=38970&view=rev
Log:
update mapi headers to wine 1.1.13
Modified:
trunk/reactos/include/psdk/mapi.h
trunk/reactos/include/psdk/mapicode.h
trunk/reactos/include/psdk/mapidefs.h
trunk/reactos/include/psdk/mapiguid.h
trunk/reactos/include/psdk/mapitags.h
trunk/reactos/include/psdk/mapiutil.h
trunk/reactos/include/psdk/mapival.h
trunk/reactos/include/psdk/mapix.h
Modified: trunk/reactos/include/psdk/mapi.h
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/mapi.h?rev=38…
==============================================================================
--- trunk/reactos/include/psdk/mapi.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/mapi.h [iso-8859-1] Tue Jan 20 02:19:52 2009
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2000 François Gouget
+ * Copyright (C) 2000 Francois Gouget
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
@@ -13,7 +13,7 @@
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#ifndef MAPI_H
@@ -27,15 +27,15 @@
#ifndef __LHANDLE
#define __LHANDLE
-typedef unsigned long LHANDLE, *LPLHANDLE;
+typedef ULONG LHANDLE, *LPLHANDLE;
#endif
#define lhSessionNull ((LHANDLE)0)
#ifndef WINE_FLAGS_DEFINED
#define WINE_FLAGS_DEFINED
-typedef unsigned long FLAGS;
-#endif
-typedef unsigned long* LPULONG;
+typedef ULONG FLAGS;
+#endif
+typedef ULONG *LPULONG;
typedef struct
{
@@ -191,7 +191,7 @@
MAPISENDDOCUMENTS MAPISendDocuments;
typedef ULONG (WINAPI MAPISENDMAIL)(LHANDLE,ULONG_PTR,lpMapiMessage,FLAGS,ULONG);
-typedef MAPISENDMAIL *LPMAPI;
+typedef MAPISENDMAIL *LPMAPISENDMAIL;
MAPISENDMAIL MAPISendMail;
#ifdef __cplusplus
Modified: trunk/reactos/include/psdk/mapicode.h
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/mapicode.h?re…
==============================================================================
--- trunk/reactos/include/psdk/mapicode.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/mapicode.h [iso-8859-1] Tue Jan 20 02:19:52 2009
@@ -15,7 +15,7 @@
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#ifndef MAPICODE_H
Modified: trunk/reactos/include/psdk/mapidefs.h
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/mapidefs.h?re…
==============================================================================
--- trunk/reactos/include/psdk/mapidefs.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/mapidefs.h [iso-8859-1] Tue Jan 20 02:19:52 2009
@@ -13,7 +13,7 @@
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#ifndef MAPIDEFS_H
@@ -24,9 +24,8 @@
#endif
#include <winerror.h>
-#ifndef _OBJBASE_H_
#include <objbase.h>
-#endif
+#include <stddef.h>
/* Some types from other headers */
#ifndef __LHANDLE
@@ -219,7 +218,7 @@
#define MVI_FLAG (MV_FLAG|MV_INSTANCE)
#define MVI_PROP(t) ((t)|MVI_FLAG)
-#ifndef __WINESRC__
+#ifndef WINE_NO_UNICODE_MACROS
# ifdef UNICODE
# define PT_TSTRING PT_UNICODE
# define PT_MV_TSTRING (MV_FLAG|PT_UNICODE)
@@ -435,7 +434,7 @@
typedef struct _SPropProblem
{
ULONG ulIndex; /* Index of the property */
- ULONG ulPropTag; /* Proprty tag of the property */
+ ULONG ulPropTag; /* Property tag of the property */
SCODE scode; /* Error code of the problem */
} SPropProblem, *LPSPropProblem;
@@ -896,17 +895,17 @@
#define IMAPIProp_AddRef(p) (p)->lpVtbl->AddRef(p)
#define IMAPIProp_Release(p) (p)->lpVtbl->Release(p)
/*** IMAPIProp methods ***/
-#define IMAPIProp_GetLastError(p,a,b,c) (p)->lpVtbl->GetLastError(p,a,b,c)
-#define IMAPIProp_SaveChanges(p,a) (p)->lpVtbl->SaveChanges(p,a)
-#define IMAPIProp_GetProps(p,a,b,c,d) (p)->lpVtbl->GetProps(p,a,b,c,d)
-#define IMAPIProp_GetPropList(p,a,b) (p)->lpVtbl->GetPropList(p,a,b)
-#define IMAPIProp_OpenProperty(p,a,b,c,d,e) (p)->lpVtbl->OpenProperty(p,a,b,c,d,e)
-#define IMAPIProp_SetProps(p,a,b,c) (p)->lpVtbl->SetProps(p,a,b,c)
-#define IMAPIProp_DeleteProps(p,a,b) (p)->lpVtbl->DeleteProps(p,a,b)
-#define IMAPIProp_CopyTo(p,a,b,c,d,e,f,g,h,i) (p)->lpVtbl->CopyTo(p,a,b,c,d,e,f,g,h,i)
-#define IMAPIProp_CopyProps(p,a,b,c,d,e,f,g) (p)->lpVtbl->CopyProps(p,a,b,c,d,e,f,g)
-#define IMAPIProp_GetNamesFromIDs(p,a,b,c,d,e) (p)->lpVtbl->GetNamesFromIDs(p,a,b,c,d,e)
-#define IMAPIProp_GetIDsFromNames(p,a,b,c,d) (p)->lpVtbl->GetIDsFromNames(p,a,b,c,d)
+#define IMAPIProp_GetLastError(p,a,b,c) (p)->lpVtbl->GetLastError(p,a,b,c)
+#define IMAPIProp_SaveChanges(p,a) (p)->lpVtbl->SaveChanges(p,a)
+#define IMAPIProp_GetProps(p,a,b,c,d) (p)->lpVtbl->GetProps(p,a,b,c,d)
+#define IMAPIProp_GetPropList(p,a,b) (p)->lpVtbl->GetPropList(p,a,b)
+#define IMAPIProp_OpenProperty(p,a,b,c,d,e) (p)->lpVtbl->OpenProperty(p,a,b,c,d,e)
+#define IMAPIProp_SetProps(p,a,b,c) (p)->lpVtbl->SetProps(p,a,b,c)
+#define IMAPIProp_DeleteProps(p,a,b) (p)->lpVtbl->DeleteProps(p,a,b)
+#define IMAPIProp_CopyTo(p,a,b,c,d,e,f,g,h,i) (p)->lpVtbl->CopyTo(p,a,b,c,d,e,f,g,h,i)
+#define IMAPIProp_CopyProps(p,a,b,c,d,e,f,g) (p)->lpVtbl->CopyProps(p,a,b,c,d,e,f,g)
+#define IMAPIProp_GetNamesFromIDs(p,a,b,c,d,e) (p)->lpVtbl->GetNamesFromIDs(p,a,b,c,d,e)
+#define IMAPIProp_GetIDsFromNames(p,a,b,c,d) (p)->lpVtbl->GetIDsFromNames(p,a,b,c,d)
#endif
typedef IMAPIProp *LPMAPIPROP;
Modified: trunk/reactos/include/psdk/mapiguid.h
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/mapiguid.h?re…
==============================================================================
--- trunk/reactos/include/psdk/mapiguid.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/mapiguid.h [iso-8859-1] Tue Jan 20 02:19:52 2009
@@ -13,7 +13,7 @@
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#ifndef MAPIGUID_H
Modified: trunk/reactos/include/psdk/mapitags.h
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/mapitags.h?re…
==============================================================================
--- trunk/reactos/include/psdk/mapitags.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/mapitags.h [iso-8859-1] Tue Jan 20 02:19:52 2009
@@ -6,16 +6,16 @@
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
- * version 2.1 of the License,or (at your option) any later version.
+ * version 2.1 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
- * License along with this library; if not,write to the Free Software
- * Foundation,Inc.,59 Temple Place,Suite 330,Boston,MA 02111-1307 USA
+ * License along with this library; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#ifndef MAPITAGS_H
#define MAPITAGS_H
@@ -415,7 +415,7 @@
#define PR_IPM_OUTBOX_SEARCH_KEY PROP_TAG(PT_BINARY,0x3411)
#define PR_IPM_WASTEBASKET_SEARCH_KEY PROP_TAG(PT_BINARY,0x3412)
#define PR_IPM_SENTMAIL_SEARCH_KEY PROP_TAG(PT_BINARY,0x3413)
-/* Provder-defined message store type */
+/* Provider-defined message store type */
#define PR_MDB_PROVIDER PROP_TAG(PT_BINARY,0x3414)
#define PR_RECEIVE_FOLDER_SETTINGS PROP_TAG(PT_OBJECT,0x3415)
#define PR_VALID_FOLDER_MASK PROP_TAG(PT_I4,0x35DF)
Modified: trunk/reactos/include/psdk/mapiutil.h
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/mapiutil.h?re…
==============================================================================
--- trunk/reactos/include/psdk/mapiutil.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/mapiutil.h [iso-8859-1] Tue Jan 20 02:19:52 2009
@@ -13,7 +13,7 @@
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#ifndef MAPIUTIL_H_
@@ -175,7 +175,7 @@
static inline FILETIME FtAddFt(FILETIME ftLeft, FILETIME ftRight)
{
LONG64 *pl = (LONG64*)&ftLeft, *pr = (LONG64*)&ftRight;
- union { FILETIME ft; LONG64 ll; } ftmap;
+ union { FILETIME ft; LONG64 ll; } ftmap;
ftmap.ll = *pl + *pr;
return ftmap.ft;
}
@@ -183,7 +183,7 @@
static inline FILETIME FtSubFt(FILETIME ftLeft, FILETIME ftRight)
{
LONG64 *pl = (LONG64*)&ftLeft, *pr = (LONG64*)&ftRight;
- union { FILETIME ft; LONG64 ll; } ftmap;
+ union { FILETIME ft; LONG64 ll; } ftmap;
ftmap.ll = *pl - *pr;
return ftmap.ft;
}
@@ -191,7 +191,7 @@
static inline FILETIME FtNegFt(FILETIME ftLeft)
{
LONG64 *p = (LONG64*)&ftLeft;
- union { FILETIME ft; LONG64 ll; } ftmap;
+ union { FILETIME ft; LONG64 ll; } ftmap;
ftmap.ll = -*p;
return ftmap.ft;
}
@@ -199,7 +199,7 @@
static inline FILETIME FtMulDw(DWORD dwLeft, FILETIME ftRight)
{
LONG64 l = (LONG64)dwLeft, *pr = (LONG64*)&ftRight;
- union { FILETIME ft; LONG64 ll; } ftmap;
+ union { FILETIME ft; LONG64 ll; } ftmap;
ftmap.ll = l * (*pr);
return ftmap.ft;
}
@@ -207,7 +207,7 @@
static inline FILETIME FtMulDwDw(DWORD dwLeft, DWORD dwRight)
{
LONG64 l = (LONG64)dwLeft, r = (LONG64)dwRight;
- union { FILETIME ft; LONG64 ll; } ftmap;
+ union { FILETIME ft; LONG64 ll; } ftmap;
ftmap.ll = l * r;
return ftmap.ft;
}
@@ -253,17 +253,17 @@
#define IPropData_AddRef(p) (p)->lpVtbl->AddRef(p)
#define IPropData_Release(p) (p)->lpVtbl->Release(p)
/*** IMAPIProp methods ***/
-#define IPropData_GetLastError(p,a,b,c) (p)->lpVtbl->GetLastError(p,a,b,c)
-#define IPropData_SaveChanges(p,a) (p)->lpVtbl->SaveChanges(p,a)
-#define IPropData_GetProps(p,a,b,c,d) (p)->lpVtbl->GetProps(p,a,b,c,d)
-#define IPropData_GetPropList(p,a,b) (p)->lpVtbl->GetPropList(p,a,b)
-#define IPropData_OpenProperty(p,a,b,c,d,e) (p)->lpVtbl->OpenProperty(p,a,b,c,d,e)
-#define IPropData_SetProps(p,a,b,c) (p)->lpVtbl->SetProps(p,a,b,c)
-#define IPropData_DeleteProps(p,a,b) (p)->lpVtbl->DeleteProps(p,a,b)
-#define IPropData_CopyTo(p,a,b,c,d,e,f,g,h,i) (p)->lpVtbl->CopyTo(p,a,b,c,d,e,f,g,h,i)
-#define IPropData_CopyProps(p,a,b,c,d,e,f,g) (p)->lpVtbl->CopyProps(p,a,b,c,d,e,f,g)
-#define IPropData_GetNamesFromIDs(p,a,b,c,d,e) (p)->lpVtbl->GetNamesFromIDs(p,a,b,c,d,e)
-#define IPropData_GetIDsFromNames(p,a,b,c,d) (p)->lpVtbl->GetIDsFromNames(p,a,b,c,d)
+#define IPropData_GetLastError(p,a,b,c) (p)->lpVtbl->GetLastError(p,a,b,c)
+#define IPropData_SaveChanges(p,a) (p)->lpVtbl->SaveChanges(p,a)
+#define IPropData_GetProps(p,a,b,c,d) (p)->lpVtbl->GetProps(p,a,b,c,d)
+#define IPropData_GetPropList(p,a,b) (p)->lpVtbl->GetPropList(p,a,b)
+#define IPropData_OpenProperty(p,a,b,c,d,e) (p)->lpVtbl->OpenProperty(p,a,b,c,d,e)
+#define IPropData_SetProps(p,a,b,c) (p)->lpVtbl->SetProps(p,a,b,c)
+#define IPropData_DeleteProps(p,a,b) (p)->lpVtbl->DeleteProps(p,a,b)
+#define IPropData_CopyTo(p,a,b,c,d,e,f,g,h,i) (p)->lpVtbl->CopyTo(p,a,b,c,d,e,f,g,h,i)
+#define IPropData_CopyProps(p,a,b,c,d,e,f,g) (p)->lpVtbl->CopyProps(p,a,b,c,d,e,f,g)
+#define IPropData_GetNamesFromIDs(p,a,b,c,d,e) (p)->lpVtbl->GetNamesFromIDs(p,a,b,c,d,e)
+#define IPropData_GetIDsFromNames(p,a,b,c,d) (p)->lpVtbl->GetIDsFromNames(p,a,b,c,d)
#define IPropData_HrSetObjAccess(p,a) (p)->lpVtbl->HrSetObjAccess(p,a)
#define IPropData_HrSetPropAccess(p,a,b) (p)->lpVtbl->HrSetPropAccess(p,a,b)
#define IPropData_HrGetPropAccess(p,a,b) (p)->lpVtbl->HrGetPropAccess(p,a,b)
Modified: trunk/reactos/include/psdk/mapival.h
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/mapival.h?rev…
==============================================================================
--- trunk/reactos/include/psdk/mapival.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/mapival.h [iso-8859-1] Tue Jan 20 02:19:52 2009
@@ -13,7 +13,7 @@
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#ifndef MAPIVAL_H
@@ -24,6 +24,8 @@
#endif
#include <mapiutil.h>
+#include <stddef.h>
+#include <stdarg.h>
BOOL WINAPI FBadRglpszW(LPWSTR*,ULONG);
BOOL WINAPI FBadRowSet(LPSRowSet);
Modified: trunk/reactos/include/psdk/mapix.h
URL: http://svn.reactos.org/svn/reactos/trunk/reactos/include/psdk/mapix.h?rev=3…
==============================================================================
--- trunk/reactos/include/psdk/mapix.h [iso-8859-1] (original)
+++ trunk/reactos/include/psdk/mapix.h [iso-8859-1] Tue Jan 20 02:19:52 2009
@@ -13,24 +13,16 @@
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
- * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
#ifndef MAPIX_H
#define MAPIX_H
-#ifndef MAPIDEFS_H
#include <mapidefs.h>
-#endif
-#ifndef MAPICODE_H
#include <mapicode.h>
-#endif
-#ifndef MAPIGUID_H
#include <mapiguid.h>
-#endif
-#ifndef MAPITAGS_H
#include <mapitags.h>
-#endif
#ifdef __cplusplus
extern "C" {
@@ -44,7 +36,7 @@
#ifndef WINE_FLAGS_DEFINED
#define WINE_FLAGS_DEFINED
-typedef unsigned long FLAGS;
+typedef ULONG FLAGS;
#endif
/* Flags for MAPILogon and MAPILogonEx */
@@ -113,6 +105,10 @@
typedef MAPIFREEBUFFER *LPMAPIFREEBUFFER;
MAPIFREEBUFFER MAPIFreeBuffer;
#endif
+
+typedef HRESULT (WINAPI MAPIADMINPROFILES)(ULONG,LPPROFADMIN*);
+typedef MAPIADMINPROFILES *LPMAPIADMINPROFILES;
+MAPIADMINPROFILES MAPIAdminProfiles;
/*****************************************************************************
* IMAPISession interface
Author: tkreuzer
Date: Mon Jan 19 19:50:13 2009
New Revision: 38965
URL: http://svn.reactos.org/svn/reactos?rev=38965&view=rev
Log:
kdcom: add a debug hack to use com2 for WinDbg, while com1 stays for FrLdrDbgPrint. Also mark the Port as initialized in KdDebuggerInitialize0. Remove the KD_RECV_CODE enum, use the KDSTATUS enum that already exist. Implement PACKET_TYPE_KD_POLL_BREAKIN case for KdReceivePacket as described in http://www.nynaeve.net/?p=169 Now we return from KdPollBreakIn().
Modified:
branches/ros-amd64-bringup/reactos/drivers/base/kdcom/i386/kdbg.c
Modified: branches/ros-amd64-bringup/reactos/drivers/base/kdcom/i386/kdbg.c
URL: http://svn.reactos.org/svn/reactos/branches/ros-amd64-bringup/reactos/drive…
==============================================================================
--- branches/ros-amd64-bringup/reactos/drivers/base/kdcom/i386/kdbg.c [iso-8859-1] (original)
+++ branches/ros-amd64-bringup/reactos/drivers/base/kdcom/i386/kdbg.c [iso-8859-1] Mon Jan 19 19:50:13 2009
@@ -21,13 +21,6 @@
#include "windbgkd.h"
#include <kddll.h>
#include <ioaccess.h> /* port intrinsics */
-
-typedef enum _KD_RECV_CODE
-{
- KD_RECV_CODE_OK = 0,
- KD_RECV_CODE_TIMEOUT = 1,
- KD_RECV_CODE_FAILED = 2
-} KD_RECV_CODE, * PKD_RECV_CODE;
typedef struct _KD_PORT_INFORMATION
{
@@ -541,13 +534,14 @@
}
}
+
/******************************************************************************
* \name KdpReceiveBuffer
* \brief Recieves 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 KD_RECV_CODE_OK if successful.
- * KD_RECV_CODE_TIMEOUT if the receice timed out (10 seconds).
+ * \return KdPacketReceived if successful.
+ * KdPacketTimedOut if the receice timed out (10 seconds).
* \todo Handle timeout.
*/
KDSTATUS
@@ -571,12 +565,12 @@
if (TimeOut)
{
- return KD_RECV_CODE_TIMEOUT;
+ return KdPacketTimedOut;
}
FrLdrDbgPrint("Received byte: %x\n", ByteBuffer[i]);
}
- return KD_RECV_CODE_OK;
+ return KdPacketReceived;
}
/* NEW PUBLIC FUNCTIONS ******************************************************/
@@ -679,6 +673,9 @@
}
}
+ // HACK use com1 for FrLdrDbg, com2 for WinDbg
+ DefaultPort.ComPort = 2;
+
/* Get base address */
DefaultPort.BaseAddress = BaseArray[DefaultPort.ComPort];
@@ -690,6 +687,7 @@
/* Initialize the port */
KdPortInitializeEx(&DefaultPort, 0, 0);
+ PortInitialized = TRUE;
return STATUS_SUCCESS;
}
@@ -707,7 +705,6 @@
{
// HACK: misuse this function to get a pointer to FrLdrDbgPrint
FrLdrDbgPrint = (PVOID)LoaderBlock;
- UNIMPLEMENTED;
return STATUS_NOT_IMPLEMENTED;
}
@@ -774,8 +771,21 @@
return;
}
-/*
- * @unimplemented
+
+/******************************************************************************
+ * \name KdReceivePacket
+ * \brief Receive a packet from the KD port.
+ * \param [in] PacketType Describes the type of the packet to receive.
+ * This can be one of the PACKET_TYPE_ constants.
+ * \param [out] MessageHeader Pointer to a STRING structure for the header.
+ * \param [out] MessageData Pointer to a STRING structure for the data.
+ * \return KdPacketReceived if successful, KdPacketTimedOut if the receive
+ * timed out, KdPacketNeedsResend to signal that the last packet needs
+ * to be sent again.
+ * \note If PacketType is PACKET_TYPE_KD_POLL_BREAKIN, the function doesn't
+ * wait for any data, but returns KdPacketTimedOut instantly if no breakin
+ * packet byte is received.
+ * \sa http://www.nynaeve.net/?p=169
*/
KDSTATUS
NTAPI
@@ -786,8 +796,24 @@
OUT PULONG DataLength,
IN OUT PKD_CONTEXT Context)
{
-// UNIMPLEMENTED;
- return 0;
+ UCHAR BreakIn = 0;
+
+ /* Special handling for breakin packet */
+ if(PacketType == PACKET_TYPE_KD_POLL_BREAKIN)
+ {
+ if (KdPortGetByteEx(&DefaultPort, &BreakIn))
+ {
+ if (BreakIn == BREAKIN_PACKET_BYTE)
+ {
+ return KdPacketReceived;
+ }
+ }
+ return KdPacketTimedOut;
+ }
+
+ // FIXME: handle other cases
+
+ return KdPacketReceived;
}
/* EOF */