Add CommandLineFromMsiDescriptor
Modified: trunk/reactos/lib/advapi32/advapi32.def
Modified: trunk/reactos/lib/advapi32/advapi32.xml
Added: trunk/reactos/lib/advapi32/misc/msi.c

Modified: trunk/reactos/lib/advapi32/advapi32.def
--- trunk/reactos/lib/advapi32/advapi32.def	2005-11-17 22:06:47 UTC (rev 19317)
+++ trunk/reactos/lib/advapi32/advapi32.def	2005-11-17 23:19:29 UTC (rev 19318)
@@ -70,7 +70,7 @@
 CloseEventLog@4
 CloseServiceHandle@4
 ;CloseTrace@8
-;CommandLineFromMsiDescriptor@12
+CommandLineFromMsiDescriptor@12
 ;ComputeAccessTokenFromCodeAuthzLevel@20
 ControlService@12
 ControlServiceEx@16

Modified: trunk/reactos/lib/advapi32/advapi32.xml
--- trunk/reactos/lib/advapi32/advapi32.xml	2005-11-17 22:06:47 UTC (rev 19317)
+++ trunk/reactos/lib/advapi32/advapi32.xml	2005-11-17 23:19:29 UTC (rev 19318)
@@ -24,6 +24,7 @@
 		<file>dllmain.c</file>
 		<file>hwprofiles.c</file>
 		<file>logon.c</file>
+		<file>msi.c</file>
 		<file>shutdown.c</file>
 		<file>sysfunc.c</file>
 	</directory>

Added: trunk/reactos/lib/advapi32/misc/msi.c
--- trunk/reactos/lib/advapi32/misc/msi.c	2005-11-17 22:06:47 UTC (rev 19317)
+++ trunk/reactos/lib/advapi32/misc/msi.c	2005-11-17 23:19:29 UTC (rev 19318)
@@ -0,0 +1,37 @@
+/*
+ * COPYRIGHT:       See COPYING in the top level directory
+ * PROJECT:         ReactOS system libraries
+ * FILE:            lib/advapi32/misc/msi.c
+ * PURPOSE:         advapi32.dll MSI interface funcs
+ * NOTES:           Copied from Wine
+ *                  Copyright 1995 Sven Verdoolaege
+ */
+
+#include <advapi32.h>
+
+#define NDEBUG
+#include <debug.h>
+
+typedef UINT (WINAPI *fnMsiProvideComponentFromDescriptor)(LPCWSTR,LPWSTR,DWORD*,DWORD*);
+
+DWORD WINAPI CommandLineFromMsiDescriptor( WCHAR *szDescriptor,
+                    WCHAR *szCommandLine, DWORD *pcchCommandLine )
+{
+    static const WCHAR szMsi[] = { 'm','s','i',0 };
+    fnMsiProvideComponentFromDescriptor mpcfd;
+    HMODULE hmsi;
+    UINT r = ERROR_CALL_NOT_IMPLEMENTED;
+
+    DPRINT("%S %p %p\n", szDescriptor, szCommandLine, pcchCommandLine);
+
+    hmsi = LoadLibraryW( szMsi );
+    if (!hmsi)
+        return r;
+    mpcfd = (void*) GetProcAddress( hmsi, "MsiProvideComponentFromDescriptorW" );
+    if (mpcfd)
+        r = mpcfd( szDescriptor, szCommandLine, pcchCommandLine, NULL );
+    FreeLibrary( hmsi );
+    return r;
+}
+
+/* EOF */
Property changes on: trunk/reactos/lib/advapi32/misc/msi.c
___________________________________________________________________
Name: svn:keywords
   + Author Date Id Revision
Name: svn:eol-style
   + native