Added some MAPI stubs.
diff --git a/dlls/mapi32/mapi32.spec b/dlls/mapi32/mapi32.spec
index 6d8d8b4..e2c4fbb 100644
--- a/dlls/mapi32/mapi32.spec
+++ b/dlls/mapi32/mapi32.spec
@@ -3,7 +3,7 @@
import ntdll.dll
-debug_channels()
+debug_channels (mapi)
@ stub BMAPIAddress
@ stub BMAPIDetails
@@ -94,7 +94,7 @@
@ stub MAPIAddress
@ stub MAPIAdminProfiles
# @ stub MAPIAdminProfiles@8
-@ stub MAPIAllocateBuffer
+@ stdcall MAPIAllocateBuffer(long ptr) MAPIAllocateBuffer
# @ stub MAPIAllocateBuffer@8
@ stub MAPIAllocateMore
# @ stub MAPIAllocateMore@12
@@ -106,11 +106,11 @@
# @ stub MAPIFreeBuffer@4
@ stub MAPIGetDefaultMalloc@0
@ stub MAPIInitIdle@4
-@ stub MAPIInitialize
+@ stdcall MAPIInitialize(ptr) MAPIInitialize
# @ stub MAPIInitialize@4
@ stub MAPILogoff
-@ stub MAPILogon
-@ stub MAPILogonEx
+@ stdcall MAPILogon(long ptr ptr long long ptr) MAPILogon
+@ stdcall MAPILogonEx(long ptr ptr long ptr) MAPILogonEx
# @ stub MAPILogonEx@20
@ stub MAPIOpenFormMgr
# @ stub MAPIOpenFormMgr@8
@@ -121,7 +121,7 @@
@ stub MAPISaveMail
@ stub MAPISendDocuments
@ stub MAPISendMail
-@ stub MAPIUninitialize
+@ stdcall MAPIUninitialize() MAPIUninitialize
# @ stub MAPIUninitialize@0
@ stub MNLS_CompareStringW@24
@ stub MNLS_IsBadStringPtrW@8
diff --git a/dlls/mapi32/mapi32_main.c b/dlls/mapi32/mapi32_main.c
index 67a01ed..3c4132c 100644
--- a/dlls/mapi32/mapi32_main.c
+++ b/dlls/mapi32/mapi32_main.c
@@ -1 +1,45 @@
-/* nothing here yet */
+/*
+ * MAPI basics
+ *
+ * 2001 Codeweavers Inc.
+ */
+
+#include "windef.h"
+#include "winerror.h"
+#include "mapi.h"
+#include "mapicode.h"
+#include "debugtools.h"
+
+DEFAULT_DEBUG_CHANNEL(mapi);
+
+HRESULT WINAPI MAPIInitialize ( LPVOID lpMapiInit )
+{
+ ERR("Stub\n");
+ return MAPI_E_NOT_INITIALIZED;
+}
+
+HRESULT WINAPI MAPIAllocateBuffer ( ULONG cvSize, LPVOID *lppBuffer )
+{
+ ERR("Stub\n");
+ *lppBuffer = NULL;
+ return MAPI_E_NOT_INITIALIZED;
+}
+
+ULONG WINAPI MAPILogon(ULONG ulUIParam, LPSTR lpszProfileName, LPSTR
+lpszPassword, FLAGS flFlags, ULONG ulReserver, LPLHANDLE lplhSession)
+{
+ ERR("Stub\n");
+ return MAPI_E_FAILURE;
+}
+
+HRESULT WINAPI MAPILogonEx( ULONG ulUIParam, LPSTR lpszProfileName, LPSTR
+lpszPassword, FLAGS flFlags, VOID* lppSession)
+{
+ ERR("Stub\n");
+ return MAPI_E_LOGON_FAILURE;
+}
+
+VOID WINAPI MAPIUninitialize()
+{
+ ERR("Stub\n");
+}
diff --git a/include/Makefile.in b/include/Makefile.in
index 3f70e95..9a9b680 100644
--- a/include/Makefile.in
+++ b/include/Makefile.in
@@ -43,6 +43,7 @@
lmcons.h \
lzexpand.h \
mapi.h \
+ mapicode.h \
mapidefs.h \
mciavi.h \
mcx.h \
diff --git a/include/mapi.h b/include/mapi.h
index 356e660..b063ea2 100644
--- a/include/mapi.h
+++ b/include/mapi.h
@@ -7,7 +7,6 @@
/* Some types */
-typedef unsigned char* LPBYTE;
#ifndef __LHANDLE
#define __LHANDLE
typedef unsigned long LHANDLE, *LPLHANDLE;
diff --git a/include/mapicode.h b/include/mapicode.h
new file mode 100644
index 0000000..4795c02
--- /dev/null
+++ b/include/mapicode.h
@@ -0,0 +1,16 @@
+/*
+ * status codes returned by MAPI
+ */
+
+#ifndef MAPICODE_H
+#define MAPICODE_H
+
+#define MAKE_MAPI_SCODE(sev,fac,code) \
+ ( (((ULONG)(sev)<<31) | ((ULONG)(fac)<<16) | ((ULONG)(code))) )
+
+#define MAKE_MAPI_E( err ) (MAKE_MAPI_SCODE(1, FACILITY_ITF, err ))
+
+#define MAPI_E_NOT_INITIALIZED MAKE_MAPI_E( 0x605)
+
+
+#endif