https://git.reactos.org/?p=reactos.git;a=commitdiff;h=89236be2cc6db95fae298…
commit 89236be2cc6db95fae2986f4b2f07cb286aec1aa
Author: Amine Khaldi <amine.khaldi(a)reactos.org>
AuthorDate: Fri Mar 9 12:41:26 2018 +0100
Commit: Amine Khaldi <amine.khaldi(a)reactos.org>
CommitDate: Fri Mar 9 12:41:26 2018 +0100
[ADVPACK] Sync with Wine Staging 3.3. CORE-14434
---
dll/win32/advpack/CMakeLists.txt | 4 ++--
dll/win32/advpack/advpack.c | 14 ++++++++++++++
dll/win32/advpack/advpack_private.h | 28 +---------------------------
dll/win32/advpack/files.c | 17 +++++++++++++++--
dll/win32/advpack/install.c | 16 +++++++++++++++-
dll/win32/advpack/precomp.h | 23 +++++++++++++++++++++++
dll/win32/advpack/reg.c | 13 ++++++++++++-
media/doc/README.WINE | 2 +-
8 files changed, 83 insertions(+), 34 deletions(-)
diff --git a/dll/win32/advpack/CMakeLists.txt b/dll/win32/advpack/CMakeLists.txt
index 71abc63857..585927435c 100644
--- a/dll/win32/advpack/CMakeLists.txt
+++ b/dll/win32/advpack/CMakeLists.txt
@@ -8,7 +8,7 @@ list(APPEND SOURCE
files.c
install.c
reg.c
- advpack_private.h)
+ precomp.h)
add_library(advpack SHARED
${SOURCE}
@@ -18,5 +18,5 @@ add_library(advpack SHARED
set_module_type(advpack win32dll)
target_link_libraries(advpack wine)
add_importlibs(advpack ole32 setupapi version advapi32 msvcrt kernel32 ntdll)
-add_pch(advpack advpack_private.h SOURCE)
+add_pch(advpack precomp.h SOURCE)
add_cd_file(TARGET advpack DESTINATION reactos/system32 FOR all)
diff --git a/dll/win32/advpack/advpack.c b/dll/win32/advpack/advpack.c
index 4f1b41c0b7..d2ce60e3e2 100644
--- a/dll/win32/advpack/advpack.c
+++ b/dll/win32/advpack/advpack.c
@@ -19,8 +19,22 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
+#include <stdarg.h>
+
+#include "windef.h"
+#include "winbase.h"
+#include "winuser.h"
+#include "winreg.h"
+#include "winternl.h"
+#include "winnls.h"
+#include "setupapi.h"
+#include "advpub.h"
+#include "wine/unicode.h"
+#include "wine/debug.h"
#include "advpack_private.h"
+WINE_DEFAULT_DEBUG_CHANNEL(advpack);
+
typedef HRESULT (WINAPI *DLLREGISTER) (void);
#define MAX_FIELD_LENGTH 512
diff --git a/dll/win32/advpack/advpack_private.h b/dll/win32/advpack/advpack_private.h
index 5ebfe6332d..fc3b26f393 100644
--- a/dll/win32/advpack/advpack_private.h
+++ b/dll/win32/advpack/advpack_private.h
@@ -21,23 +21,7 @@
#ifndef __ADVPACK_PRIVATE_H
#define __ADVPACK_PRIVATE_H
-#include <stdarg.h>
-
-#define WIN32_NO_STATUS
-#define _INC_WINDOWS
-#define COM_NO_WINDOWS_H
-
-#include <windef.h>
-#include <winbase.h>
-#include <winuser.h>
-#include <winreg.h>
-#include <winternl.h>
-#include <advpub.h>
-
-#include <wine/debug.h>
-#include <wine/unicode.h>
-
-WINE_DEFAULT_DEBUG_CHANNEL(advpack);
+#include "wine/heap.h"
HRESULT do_ocx_reg(HMODULE hocx, BOOL do_reg, const WCHAR *flags, const WCHAR *param)
DECLSPEC_HIDDEN;
LPWSTR get_parameter(LPWSTR *params, WCHAR separator, BOOL quoted) DECLSPEC_HIDDEN;
@@ -45,16 +29,6 @@ void set_ldids(HINF hInf, LPCWSTR pszInstallSection, LPCWSTR
pszWorkingDir) DECL
HRESULT launch_exe(LPCWSTR cmd, LPCWSTR dir, HANDLE *phEXE) DECLSPEC_HIDDEN;
-static inline void* __WINE_ALLOC_SIZE(1) heap_alloc(size_t size)
-{
- return HeapAlloc(GetProcessHeap(), 0, size);
-}
-
-static inline BOOL heap_free(void *mem)
-{
- return HeapFree(GetProcessHeap(), 0, mem);
-}
-
static inline char *heap_strdupWtoA(const WCHAR *str)
{
char *ret = NULL;
diff --git a/dll/win32/advpack/files.c b/dll/win32/advpack/files.c
index 0a5c680c16..c5efbb2564 100644
--- a/dll/win32/advpack/files.c
+++ b/dll/win32/advpack/files.c
@@ -18,10 +18,23 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
+#include <stdarg.h>
+#include <stdlib.h>
+
+#include "windef.h"
+#include "winbase.h"
+#include "winuser.h"
+#include "winreg.h"
+#include "winver.h"
+#include "winternl.h"
+#include "setupapi.h"
+#include "advpub.h"
+#include "fdi.h"
+#include "wine/debug.h"
+#include "wine/unicode.h"
#include "advpack_private.h"
-#include <winver.h>
-#include <fdi.h>
+WINE_DEFAULT_DEBUG_CHANNEL(advpack);
/* converts an ansi double null-terminated list to a unicode list */
static LPWSTR ansi_to_unicode_list(LPCSTR ansi_list)
diff --git a/dll/win32/advpack/install.c b/dll/win32/advpack/install.c
index a1e750a2f5..dcd1dd7b97 100644
--- a/dll/win32/advpack/install.c
+++ b/dll/win32/advpack/install.c
@@ -18,9 +18,23 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
+#include <stdarg.h>
+#include <stdlib.h>
+
+#include "windef.h"
+#include "winbase.h"
+#include "winuser.h"
+#include "winreg.h"
+#include "winternl.h"
+#include "winnls.h"
+#include "setupapi.h"
+#include "advpub.h"
+#include "ole2.h"
+#include "wine/debug.h"
+#include "wine/unicode.h"
#include "advpack_private.h"
-#include <ole2.h>
+WINE_DEFAULT_DEBUG_CHANNEL(advpack);
#define SPAPI_ERROR 0xE0000000L
#define SPAPI_PREFIX 0x800F0000L
diff --git a/dll/win32/advpack/precomp.h b/dll/win32/advpack/precomp.h
new file mode 100644
index 0000000000..a1c236fe33
--- /dev/null
+++ b/dll/win32/advpack/precomp.h
@@ -0,0 +1,23 @@
+
+#ifndef _ADVPACK_PRECOMP_H
+#define _ADVPACK_PRECOMP_H
+
+#include <stdarg.h>
+
+#define WIN32_NO_STATUS
+#define _INC_WINDOWS
+#define COM_NO_WINDOWS_H
+
+#include <windef.h>
+#include <winbase.h>
+#include <winuser.h>
+#include <winreg.h>
+#include <winternl.h>
+#include <advpub.h>
+
+#include <wine/debug.h>
+#include <wine/unicode.h>
+
+#include "advpack_private.h"
+
+#endif /* !_ADVPACK_PRECOMP_H */
diff --git a/dll/win32/advpack/reg.c b/dll/win32/advpack/reg.c
index 2e467999e1..9a430159ec 100644
--- a/dll/win32/advpack/reg.c
+++ b/dll/win32/advpack/reg.c
@@ -18,7 +18,18 @@
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
*/
-#include "advpack_private.h"
+#include <stdarg.h>
+#include "windef.h"
+#include "winbase.h"
+#include "winreg.h"
+#include "winerror.h"
+#include "winuser.h"
+#include "winternl.h"
+#include "advpub.h"
+#include "wine/unicode.h"
+#include "wine/debug.h"
+
+WINE_DEFAULT_DEBUG_CHANNEL(advpack);
static const WCHAR REGINST[] =
{'R','E','G','I','N','S','T',0};
static const WCHAR Strings[] =
{'S','t','r','i','n','g','s',0};
diff --git a/media/doc/README.WINE b/media/doc/README.WINE
index ff96bab112..e37d01ddab 100644
--- a/media/doc/README.WINE
+++ b/media/doc/README.WINE
@@ -44,7 +44,7 @@ reactos/dll/directx/wine/wined3d # Synced to WineStaging-3.3
reactos/dll/win32/activeds # Synced to WineStaging-3.3
reactos/dll/win32/actxprxy # Synced to WineStaging-3.3
-reactos/dll/win32/advpack # Synced to WineStaging-2.9
+reactos/dll/win32/advpack # Synced to WineStaging-3.3
reactos/dll/win32/atl # Synced to Wine-3.0
reactos/dll/win32/atl80 # Synced to Wine-3.0
reactos/dll/win32/atl100 # Synced to Wine-3.0