Rebase against d0727decdedb5aba250038458e0a28dec5687e50

This commit is contained in:
Alistair Leslie-Hughes 2019-02-12 09:28:02 +11:00
parent c6aeba1397
commit 697fe8b5da
15 changed files with 11 additions and 755 deletions

View File

@ -1 +1,2 @@
Fixes: [42734] Implement NormalizeString
Disabled: true

View File

@ -1,4 +1,4 @@
From f840f5b4a1378ee7e1c669547deb8cce1325909c Mon Sep 17 00:00:00 2001
From cf75e3e8e4019a302ef808c31090b52fb546feb0 Mon Sep 17 00:00:00 2001
From: Dmitry Timoshkov <dmitry@baikal.ru>
Date: Mon, 2 Jan 2017 15:34:21 +0800
Subject: [PATCH] server: All fields up to CheckSum are mandatory regardless of
@ -9,12 +9,12 @@ Subject: [PATCH] server: All fields up to CheckSum are mandatory regardless of
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/server/mapping.c b/server/mapping.c
index 2955766..877eec1 100644
index 37c17b0..9f7cd7b 100644
--- a/server/mapping.c
+++ b/server/mapping.c
@@ -580,11 +580,10 @@ static unsigned int get_image_params( struct mapping *mapping, file_pos_t file_s
if (dos.e_magic != IMAGE_DOS_SIGNATURE) return STATUS_INVALID_IMAGE_NOT_MZ;
pos = dos.e_lfanew;
@@ -588,11 +588,10 @@ static unsigned int get_image_params( struct mapping *mapping, file_pos_t file_s
mz_size = size;
pos = mz.dos.e_lfanew;
+ /* zero out header in the case it's not present or partial */
+ memset( &nt, 0, sizeof(nt) );
@ -26,7 +26,7 @@ index 2955766..877eec1 100644
if (nt.Signature != IMAGE_NT_SIGNATURE)
{
IMAGE_OS2_HEADER *os2 = (IMAGE_OS2_HEADER *)&nt;
@@ -597,6 +596,10 @@ static unsigned int get_image_params( struct mapping *mapping, file_pos_t file_s
@@ -605,6 +604,10 @@ static unsigned int get_image_params( struct mapping *mapping, file_pos_t file_s
switch (nt.opt.hdr32.Magic)
{
case IMAGE_NT_OPTIONAL_HDR32_MAGIC:
@ -37,7 +37,7 @@ index 2955766..877eec1 100644
switch (nt.FileHeader.Machine)
{
case IMAGE_FILE_MACHINE_I386:
@@ -639,6 +642,10 @@ static unsigned int get_image_params( struct mapping *mapping, file_pos_t file_s
@@ -650,6 +653,10 @@ static unsigned int get_image_params( struct mapping *mapping, file_pos_t file_s
break;
case IMAGE_NT_OPTIONAL_HDR64_MAGIC:
@ -49,5 +49,5 @@ index 2955766..877eec1 100644
switch (nt.FileHeader.Machine)
{
--
2.7.4
1.9.1

View File

@ -1,3 +1,3 @@
Fixes: [10767] Fix comparison of punctuation characters in lstrcmp
Fixes: [32490] Graphical issues in Inquisitor
Depends: kernel32-NormalizeString
#Depends: kernel32-NormalizeString

View File

@ -1,30 +0,0 @@
From 2689c394dda377cdda8099164e561bfed4b07962 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Michael=20M=C3=BCller?= <michael@fds-team.de>
Date: Wed, 15 Feb 2017 16:50:04 +0100
Subject: ntdll: Improve speed of LdrGetDllHandle when searching for the
basename of modules that are not loaded.
FIXME: Can we do a similar optimization when the activation context is present?
---
dlls/ntdll/loader.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/dlls/ntdll/loader.c b/dlls/ntdll/loader.c
index 1168bad03ae..97cde883545 100644
--- a/dlls/ntdll/loader.c
+++ b/dlls/ntdll/loader.c
@@ -2506,6 +2506,11 @@ static NTSTATUS find_dll_file( const WCHAR *load_path, const WCHAR *libname,
RtlFreeHeap( GetProcessHeap(), 0, dllname );
return status;
}
+ else if (!handle)
+ {
+ /* Do not resolve full name if basename cannot be found */
+ return STATUS_DLL_NOT_FOUND;
+ }
}
if (RtlDetermineDosPathNameType_U( libname ) == RELATIVE_PATH)
--
2.11.0

View File

@ -1 +0,0 @@
Fixes: Improve performance of LdrGetDllHandle when DLL is not loaded

View File

@ -52,7 +52,7 @@ usage()
# Get the upstream commit sha
upstream_commit()
{
echo "f7b3120991df02ecaa975c18c6421fedb48ae731"
echo "d0727decdedb5aba250038458e0a28dec5687e50"
}
# Show version information
@ -166,7 +166,6 @@ patch_enable_all ()
enable_kernel32_Job_Tests="$1"
enable_kernel32_K32GetPerformanceInfo="$1"
enable_kernel32_NeedCurrentDirectoryForExePath="$1"
enable_kernel32_NormalizeString="$1"
enable_kernel32_PE_Loader_Fixes="$1"
enable_kernel32_Processor_Group="$1"
enable_kernel32_Profile="$1"
@ -206,7 +205,6 @@ patch_enable_all ()
enable_ntdll_Interrupt_0x2e="$1"
enable_ntdll_Junction_Points="$1"
enable_ntdll_LDR_MODULE="$1"
enable_ntdll_LdrGetDllHandle="$1"
enable_ntdll_LdrInitializeThunk="$1"
enable_ntdll_Manifest_Range="$1"
enable_ntdll_NtAccessCheck="$1"
@ -324,7 +322,6 @@ patch_enable_all ()
enable_version_VerFindFileA="$1"
enable_version_VerQueryValue="$1"
enable_virtdisk_OpenVirtualDisk="$1"
enable_vssapi_CreateVssBackupComponents="$1"
enable_widl_SLTG_Typelib_Support="$1"
enable_windowscodecs_32bppPRGBA="$1"
enable_windowscodecs_GIF_Encoder="$1"
@ -356,7 +353,6 @@ patch_enable_all ()
enable_wined3d_WINED3D_RS_COLORWRITEENABLE="$1"
enable_wined3d_WINED3D_TEXF_ANISOTROPIC="$1"
enable_wined3d_mesa_texture_download="$1"
enable_wined3d_stream_frequency="$1"
enable_wined3d_wined3d_guess_gl_vendor="$1"
enable_winedbg_Process_Arguments="$1"
enable_winedevice_Default_Drivers="$1"
@ -658,9 +654,6 @@ patch_enable ()
kernel32-NeedCurrentDirectoryForExePath)
enable_kernel32_NeedCurrentDirectoryForExePath="$2"
;;
kernel32-NormalizeString)
enable_kernel32_NormalizeString="$2"
;;
kernel32-PE_Loader_Fixes)
enable_kernel32_PE_Loader_Fixes="$2"
;;
@ -778,9 +771,6 @@ patch_enable ()
ntdll-LDR_MODULE)
enable_ntdll_LDR_MODULE="$2"
;;
ntdll-LdrGetDllHandle)
enable_ntdll_LdrGetDllHandle="$2"
;;
ntdll-LdrInitializeThunk)
enable_ntdll_LdrInitializeThunk="$2"
;;
@ -1132,9 +1122,6 @@ patch_enable ()
virtdisk-OpenVirtualDisk)
enable_virtdisk_OpenVirtualDisk="$2"
;;
vssapi-CreateVssBackupComponents)
enable_vssapi_CreateVssBackupComponents="$2"
;;
widl-SLTG_Typelib_Support)
enable_widl_SLTG_Typelib_Support="$2"
;;
@ -1228,9 +1215,6 @@ patch_enable ()
wined3d-mesa_texture_download)
enable_wined3d_mesa_texture_download="$2"
;;
wined3d-stream-frequency)
enable_wined3d_stream_frequency="$2"
;;
wined3d-wined3d_guess_gl_vendor)
enable_wined3d_wined3d_guess_gl_vendor="$2"
;;
@ -2057,13 +2041,6 @@ if test "$enable_ntdll_ApiSetMap" -eq 1; then
enable_ntdll_ThreadTime=1
fi
if test "$enable_libs_Unicode_Collation" -eq 1; then
if test "$enable_kernel32_NormalizeString" -gt 1; then
abort "Patchset kernel32-NormalizeString disabled, but libs-Unicode_Collation depends on that."
fi
enable_kernel32_NormalizeString=1
fi
if test "$enable_kernel32_Processor_Group" -eq 1; then
if test "$enable_api_ms_win_Stub_DLLs" -gt 1; then
abort "Patchset api-ms-win-Stub_DLLs disabled, but kernel32-Processor_Group depends on that."
@ -3926,28 +3903,6 @@ if test "$enable_kernel32_NeedCurrentDirectoryForExePath" -eq 1; then
) >> "$patchlist"
fi
# Patchset kernel32-NormalizeString
# |
# | This patchset fixes the following Wine bugs:
# | * [#42734] Implement NormalizeString
# |
# | Modified files:
# | * dlls/kernel32/locale.c, dlls/kernel32/tests/locale.c, libs/port/compose.c, libs/port/decompose.c, libs/port/mbtowc.c,
# | tools/make_unicode
# |
if test "$enable_kernel32_NormalizeString" -eq 1; then
patch_apply kernel32-NormalizeString/0001-tools-make_unicode-Implement-full-Unicode-character-.patch
patch_apply kernel32-NormalizeString/0002-tools-make_unicode-Implement-canonical-composition-f.patch
patch_apply kernel32-NormalizeString/0003-kernel32-Implement-NormalizeString-API-function.patch
patch_apply kernel32-NormalizeString/0004-libs-Generated-make_unicode-files.patch
(
printf '%s\n' '+ { "Sergio Gómez Del Real", "tools/make_unicode: Implement full Unicode character decomposition.", 1 },';
printf '%s\n' '+ { "Sergio Gómez Del Real", "tools/make_unicode: Implement canonical composition for use in normalization.", 1 },';
printf '%s\n' '+ { "Sergio Gómez Del Real", "kernel32: Implement NormalizeString API function.", 1 },';
printf '%s\n' '+ { "Alistair Leslie-Hughes", "libs: Generated make_unicode files.", 1 },';
) >> "$patchlist"
fi
# Patchset kernel32-PE_Loader_Fixes
# |
# | This patchset fixes the following Wine bugs:
@ -4065,9 +4020,6 @@ fi
# Patchset libs-Unicode_Collation
# |
# | This patchset has the following (direct or indirect) dependencies:
# | * kernel32-NormalizeString
# |
# | This patchset fixes the following Wine bugs:
# | * [#10767] Fix comparison of punctuation characters in lstrcmp
# | * [#32490] Graphical issues in Inquisitor
@ -4649,18 +4601,6 @@ if test "$enable_ntdll_Junction_Points" -eq 1; then
) >> "$patchlist"
fi
# Patchset ntdll-LdrGetDllHandle
# |
# | Modified files:
# | * dlls/ntdll/loader.c
# |
if test "$enable_ntdll_LdrGetDllHandle" -eq 1; then
patch_apply ntdll-LdrGetDllHandle/0001-ntdll-Improve-speed-of-LdrGetDllHandle-when-searchin.patch
(
printf '%s\n' '+ { "Michael Müller", "ntdll: Improve speed of LdrGetDllHandle when searching for the basename of modules that are not loaded.", 1 },';
) >> "$patchlist"
fi
# Patchset ntdll-LdrInitializeThunk
# |
# | This patchset has the following (direct or indirect) dependencies:
@ -6651,33 +6591,6 @@ if test "$enable_virtdisk_OpenVirtualDisk" -eq 1; then
) >> "$patchlist"
fi
# Patchset vssapi-CreateVssBackupComponents
# |
# | This patchset fixes the following Wine bugs:
# | * [#37639] vssapi: Add ?CreateVssBackupComponents@@YGJPAPAVIVssBackupComponents@ stub
# | * [#46088] vssapi: Add CreateVssBackupComponentsInternal stub
# |
# | Modified files:
# | * dlls/vssapi/main.c, dlls/vssapi/vssapi.spec, include/Makefile.in, include/vsbackup.idl, include/vss.idl,
# | include/vswriter.h, include/vswriter.idl
# |
if test "$enable_vssapi_CreateVssBackupComponents" -eq 1; then
patch_apply vssapi-CreateVssBackupComponents/0001-include-Add-more-VSS_-typedefs.patch
patch_apply vssapi-CreateVssBackupComponents/0002-include-Add-VSS-writer-enum.patch
patch_apply vssapi-CreateVssBackupComponents/0003-include-Convert-header-vswriter-to-an-idl.patch
patch_apply vssapi-CreateVssBackupComponents/0004-include-Add-vsbackup.idl.patch
patch_apply vssapi-CreateVssBackupComponents/0005-vssapi-Add-CreateVssBackupComponentsInternal-stub.patch
patch_apply vssapi-CreateVssBackupComponents/0006-vssapi-Add-CreateVssBackupComponents-YGJPAPAVIVssBac.patch
(
printf '%s\n' '+ { "Alistair Leslie-Hughes", "include: Add more VSS_* typedefs.", 1 },';
printf '%s\n' '+ { "Alistair Leslie-Hughes", "include: Add VSS writer enum.", 1 },';
printf '%s\n' '+ { "Alistair Leslie-Hughes", "include: Convert header vswriter to an idl.", 1 },';
printf '%s\n' '+ { "Alistair Leslie-Hughes", "include: Add vsbackup.idl.", 1 },';
printf '%s\n' '+ { "Alistair Leslie-Hughes", "vssapi: Add CreateVssBackupComponentsInternal stub.", 1 },';
printf '%s\n' '+ { "Alistair Leslie-Hughes", "vssapi: Add ?CreateVssBackupComponents@@YGJPAPAVIVssBackupComponents@@@Z stub.", 1 },';
) >> "$patchlist"
fi
# Patchset windowscodecs-GIF_Encoder
# |
# | Modified files:
@ -7150,21 +7063,6 @@ if test "$enable_wined3d_mesa_texture_download" -eq 1; then
) >> "$patchlist"
fi
# Patchset wined3d-stream-frequency
# |
# | This patchset fixes the following Wine bugs:
# | * [#39080] wined3d: Return stream frequency of 1 if it was not set.
# |
# | Modified files:
# | * dlls/d3d9/tests/visual.c, dlls/wined3d/device.c
# |
if test "$enable_wined3d_stream_frequency" -eq 1; then
patch_apply wined3d-stream-frequency/0001-wined3d-Return-stream-frequency-of-1-if-it-was-not-s.patch
(
printf '%s\n' '+ { "Paul Gofman", "wined3d: Return stream frequency of 1 if it was not set.", 1 },';
) >> "$patchlist"
fi
# Patchset wined3d-wined3d_guess_gl_vendor
# |
# | This patchset fixes the following Wine bugs:

View File

@ -1,118 +0,0 @@
From b07afce983260fac437bf17d16c61200a1dc8bd3 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Mon, 14 Jan 2019 11:02:10 +1100
Subject: [PATCH 1/6] include: Add more VSS_* typedefs
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
include/vss.idl | 90 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 90 insertions(+)
diff --git a/include/vss.idl b/include/vss.idl
index 62335ea..a190e66 100644
--- a/include/vss.idl
+++ b/include/vss.idl
@@ -19,6 +19,8 @@
import "oaidl.idl";
typedef GUID VSS_ID;
+typedef [unique, string] WCHAR *VSS_PWSZ;
+typedef LONGLONG VSS_TIMESTAMP;
typedef enum _VSS_APPLICATION_LEVEL
{
@@ -29,3 +31,91 @@ typedef enum _VSS_APPLICATION_LEVEL
VSS_APP_FRONT_END = 3,
VSS_APP_SYSTEM_RM = 4
} VSS_APPLICATION_LEVEL;
+
+typedef enum _VSS_BACKUP_TYPE
+{
+ VSS_BT_UNDEFINED,
+ VSS_BT_FULL,
+ VSS_BT_INCREMENTAL,
+ VSS_BT_DIFFERENTIAL,
+ VSS_BT_LOG,
+ VSS_BT_COPY,
+ VSS_BT_OTHER
+} VSS_BACKUP_TYPE, *PVSS_BACKUP_TYPE;
+
+typedef enum _VSS_RESTORE_TYPE
+{
+ VSS_RTYPE_UNDEFINED,
+ VSS_RTYPE_BY_COPY,
+ VSS_RTYPE_IMPORT,
+ VSS_RTYPE_OTHER
+} VSS_RESTORE_TYPE, *PVSS_RESTORE_TYPE;
+
+typedef enum _VSS_WRITER_STATE
+{
+ VSS_WS_UNKNOWN = 0,
+ VSS_WS_STABLE,
+ VSS_WS_WAITING_FOR_FREEZE,
+ VSS_WS_WAITING_FOR_THAW,
+ VSS_WS_WAITING_FOR_POST_SNAPSHOT,
+ VSS_WS_WAITING_FOR_BACKUP_COMPLETE,
+ VSS_WS_FAILED_AT_IDENTIFY,
+ VSS_WS_FAILED_AT_PREPARE_BACKUP,
+ VSS_WS_FAILED_AT_PREPARE_SNAPSHOT,
+ VSS_WS_FAILED_AT_FREEZE,
+ VSS_WS_FAILED_AT_THAW,
+ VSS_WS_FAILED_AT_POST_SNAPSHOT,
+ VSS_WS_FAILED_AT_BACKUP_COMPLETE,
+ VSS_WS_FAILED_AT_PRE_RESTORE,
+ VSS_WS_FAILED_AT_POST_RESTORE,
+ VSS_WS_FAILED_AT_BACKUPSHUTDOWN,
+ VSS_WS_COUNT
+} VSS_WRITER_STATE, *PVSS_WRITER_STATE;
+
+typedef enum _VSS_OBJECT_TYPE
+{
+ VSS_OBJECT_UNKNOWN = 0,
+ VSS_OBJECT_NONE,
+ VSS_OBJECT_SNAPSHOT_SET,
+ VSS_OBJECT_SNAPSHOT,
+ VSS_OBJECT_PROVIDER,
+ VSS_OBJECT_TYPE_COUNT
+} VSS_OBJECT_TYPE, *PVSS_OBJECT_TYPE;
+
+typedef enum _VSS_SNAPSHOT_STATE
+{
+ VSS_SS_UNKNOWN = 0,
+ VSS_SS_PREPARING,
+ VSS_SS_PROCESSING_PREPARE,
+ VSS_SS_PREPARED,
+ VSS_SS_PROCESSING_PRECOMMIT,
+ VSS_SS_PRECOMMITTED,
+ VSS_SS_PROCESSING_COMMIT,
+ VSS_SS_COMMITTED,
+ VSS_SS_PROCESSING_POSTCOMMIT,
+ VSS_SS_PROCESSING_PREFINALCOMMIT,
+ VSS_SS_PREFINALCOMMITTED,
+ VSS_SS_PROCESSING_POSTFINALCOMMIT,
+ VSS_SS_CREATED,
+ VSS_SS_ABORTED,
+ VSS_SS_DELETED,
+ VSS_SS_POSTCOMMITTED,
+ VSS_SS_COUNT
+} VSS_SNAPSHOT_STATE, *PVSS_SNAPSHOT_STATE;
+
+typedef struct _VSS_SNAPSHOT_PROP
+{
+ VSS_ID m_SnapshotId;
+ VSS_ID m_SnapshotSetId;
+ LONG m_lSnapshotsCount;
+ VSS_PWSZ m_pwszSnapshotDeviceObject;
+ VSS_PWSZ m_pwszOriginalVolumeName;
+ VSS_PWSZ m_pwszOriginatingMachine;
+ VSS_PWSZ m_pwszServiceMachine;
+ VSS_PWSZ m_pwszExposedName;
+ VSS_PWSZ m_pwszExposedPath;
+ VSS_ID m_ProviderId;
+ LONG m_lSnapshotAttributes;
+ VSS_TIMESTAMP m_tsCreationTimestamp;
+ VSS_SNAPSHOT_STATE m_eStatus;
+} VSS_SNAPSHOT_PROP, *PVSS_SNAPSHOT_PROP;
--
1.9.1

View File

@ -1,37 +0,0 @@
From caa20a89174dcf17cd2bd561f20841d4cfb0b7bb Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Mon, 14 Jan 2019 11:07:43 +1100
Subject: [PATCH 2/6] include: Add VSS writer enum
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
include/vswriter.h | 15 +++++++++++++++
1 file changed, 15 insertions(+)
diff --git a/include/vswriter.h b/include/vswriter.h
index 043b871..ac23861 100644
--- a/include/vswriter.h
+++ b/include/vswriter.h
@@ -44,4 +44,19 @@ typedef enum
VSS_AWS_THIS_IS_ALTERNATE_WRITER
} VSS_ALTERNATE_WRITER_STATE;
+typedef enum VSS_COMPONENT_TYPE
+{
+ VSS_CT_UNDEFINED = 0,
+ VSS_CT_DATABASE,
+ VSS_CT_FILEGROUP
+} VSS_COMPONENT_TYPE;
+
+typedef enum VSS_FILE_RESTORE_STATUS
+{
+ VSS_RS_UNDEFINED = 0,
+ VSS_RS_NONE,
+ VSS_RS_ALL,
+ VSS_RS_FAILED
+} VSS_FILE_RESTORE_STATUS;
+
#endif /* ___WINE_VSWRITER_H */
--
1.9.1

View File

@ -1,162 +0,0 @@
From 409e9bf5055717c010e0f45cd085dbb78f1f4c35 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Mon, 14 Jan 2019 12:08:52 +1100
Subject: [PATCH 3/6] include: Convert header vswriter to an idl.
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
include/Makefile.in | 2 +-
include/vswriter.h | 62 ----------------------------------------------------
include/vswriter.idl | 58 ++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 59 insertions(+), 63 deletions(-)
delete mode 100644 include/vswriter.h
create mode 100644 include/vswriter.idl
diff --git a/include/Makefile.in b/include/Makefile.in
index fd47078..a4642ce 100644
--- a/include/Makefile.in
+++ b/include/Makefile.in
@@ -649,7 +649,7 @@ SOURCES = \
vss.idl \
vsstyle.h \
vssym32.h \
- vswriter.h \
+ vswriter.idl \
wbemcli.idl \
wbemdisp.idl \
wbemprov.idl \
diff --git a/include/vswriter.h b/include/vswriter.h
deleted file mode 100644
index ac23861..0000000
--- a/include/vswriter.h
+++ /dev/null
@@ -1,62 +0,0 @@
-/*
- * Copyright 2014 Hans Leidekker for CodeWeavers
- *
- * 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.
- *
- * 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
- * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
- */
-
-#ifndef __WINE_VSWRITER_H
-#define __WINE_VSWRITER_H
-
-typedef enum
-{
- VSS_UT_UNDEFINED,
- VSS_UT_BOOTABLESYSTEMSTATE,
- VSS_UT_SYSTEMSERVICE,
- VSS_UT_USERDATA,
- VSS_UT_OTHER
-} VSS_USAGE_TYPE;
-
-typedef enum
-{
- VSS_ST_UNDEFINED,
- VSS_ST_TRANSACTEDDB,
- VSS_ST_NONTRANSACTEDDB,
- VSS_ST_OTHER
-} VSS_SOURCE_TYPE;
-
-typedef enum
-{
- VSS_AWS_UNDEFINED,
- VSS_AWS_NO_ALTERNATE_WRITER,
- VSS_AWS_ALTERNATE_WRITER_EXISTS,
- VSS_AWS_THIS_IS_ALTERNATE_WRITER
-} VSS_ALTERNATE_WRITER_STATE;
-
-typedef enum VSS_COMPONENT_TYPE
-{
- VSS_CT_UNDEFINED = 0,
- VSS_CT_DATABASE,
- VSS_CT_FILEGROUP
-} VSS_COMPONENT_TYPE;
-
-typedef enum VSS_FILE_RESTORE_STATUS
-{
- VSS_RS_UNDEFINED = 0,
- VSS_RS_NONE,
- VSS_RS_ALL,
- VSS_RS_FAILED
-} VSS_FILE_RESTORE_STATUS;
-
-#endif /* ___WINE_VSWRITER_H */
diff --git a/include/vswriter.idl b/include/vswriter.idl
new file mode 100644
index 0000000..6bc6890
--- /dev/null
+++ b/include/vswriter.idl
@@ -0,0 +1,58 @@
+/*
+ * Copyright 2014 Hans Leidekker for CodeWeavers
+ *
+ * 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.
+ *
+ * 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
+ * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+import "oaidl.idl";
+
+typedef enum
+{
+ VSS_UT_UNDEFINED,
+ VSS_UT_BOOTABLESYSTEMSTATE,
+ VSS_UT_SYSTEMSERVICE,
+ VSS_UT_USERDATA,
+ VSS_UT_OTHER
+} VSS_USAGE_TYPE;
+
+typedef enum
+{
+ VSS_ST_UNDEFINED,
+ VSS_ST_TRANSACTEDDB,
+ VSS_ST_NONTRANSACTEDDB,
+ VSS_ST_OTHER
+} VSS_SOURCE_TYPE;
+
+typedef enum
+{
+ VSS_AWS_UNDEFINED,
+ VSS_AWS_NO_ALTERNATE_WRITER,
+ VSS_AWS_ALTERNATE_WRITER_EXISTS,
+ VSS_AWS_THIS_IS_ALTERNATE_WRITER
+} VSS_ALTERNATE_WRITER_STATE;
+
+typedef enum VSS_COMPONENT_TYPE
+{
+ VSS_CT_UNDEFINED = 0,
+ VSS_CT_DATABASE,
+ VSS_CT_FILEGROUP
+} VSS_COMPONENT_TYPE;
+
+typedef enum VSS_FILE_RESTORE_STATUS
+{
+ VSS_RS_UNDEFINED = 0,
+ VSS_RS_NONE,
+ VSS_RS_ALL,
+ VSS_RS_FAILED
+} VSS_FILE_RESTORE_STATUS;
--
1.9.1

View File

@ -1,130 +0,0 @@
From 8f4976596db8e71f79e592ad092eceba6191ce06 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Mon, 14 Jan 2019 12:13:04 +1100
Subject: [PATCH 4/6] include: Add vsbackup.idl
Signed-off-by: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
---
include/Makefile.in | 1 +
include/vsbackup.idl | 97 ++++++++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 98 insertions(+)
create mode 100644 include/vsbackup.idl
diff --git a/include/Makefile.in b/include/Makefile.in
index a4642ce..eaf3114 100644
--- a/include/Makefile.in
+++ b/include/Makefile.in
@@ -646,6 +646,7 @@ SOURCES = \
virtdisk.h \
vmr9.idl \
vmrender.idl \
+ vsbackup.idl \
vss.idl \
vsstyle.h \
vssym32.h \
diff --git a/include/vsbackup.idl b/include/vsbackup.idl
new file mode 100644
index 0000000..0b5a2d3
--- /dev/null
+++ b/include/vsbackup.idl
@@ -0,0 +1,97 @@
+/*
+ * Copyright 2019 Alistair Leslie-Hughes
+ *
+ * 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.
+ *
+ * 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
+ * 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., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
+ */
+
+import "oaidl.idl";
+import "vswriter.idl";
+import "vss.idl";
+
+interface IVssAsync;
+interface IVssEnumObject;
+interface IVssExamineWriterMetadata;
+interface IVssWriterComponentsExt;
+
+[
+ uuid("665c1d5f-c218-414d-a05d-7fef5f9d5c86"),
+ local
+]
+interface IVssBackupComponents : IUnknown
+{
+ HRESULT GetWriterComponentsCount([out] UINT *components);
+ HRESULT GetWriterComponents([in] UINT index, [out] IVssWriterComponentsExt **writer);
+ HRESULT InitializeForBackup( [in, optional, defaultvalue(NULL)] BSTR bstrXML);
+ HRESULT SetBackupState([in] BOOL select_components, [in] BOOL state,
+ [in] VSS_BACKUP_TYPE type, [in, defaultvalue(FALSE)] BOOL partial_support);
+ HRESULT InitializeForRestore([in] BSTR xml);
+ HRESULT SetRestoreState([in] VSS_RESTORE_TYPE restore);
+ HRESULT GatherWriterMetadata([out] IVssAsync **async);
+ HRESULT GetWriterMetadataCount([out] UINT *count);
+ HRESULT GetWriterMetadata([in] UINT index, [out] VSS_ID *instance, [out] IVssExamineWriterMetadata **metadata);
+ HRESULT FreeWriterMetadata();
+ HRESULT AddComponent([in] VSS_ID instance, [in] VSS_ID id, [in] VSS_COMPONENT_TYPE ct, [in] LPCWSTR wszLogicalPath,
+ [in] LPCWSTR name);
+ HRESULT PrepareForBackup([out] IVssAsync **async);
+ HRESULT AbortBackup();
+ HRESULT GatherWriterStatus([out] IVssAsync **async);
+ HRESULT GetWriterStatusCount([out] UINT *count);
+ HRESULT FreeWriterStatus();
+ HRESULT GetWriterStatus([in] UINT index, [out] VSS_ID *instance, [out] VSS_ID *id, [out] BSTR *writer,
+ [out] VSS_WRITER_STATE *status, [out] HRESULT *failure);
+ HRESULT SetBackupSucceeded([in] VSS_ID instance, [in] VSS_ID id, [in] VSS_COMPONENT_TYPE ct,
+ [in] LPCWSTR path, [in] LPCWSTR name, [in] BOOL succeded);
+ HRESULT SetBackupOptions([in] VSS_ID id, [in] VSS_COMPONENT_TYPE ct, [in] LPCWSTR path,
+ [in] LPCWSTR name, [in] LPCWSTR options);
+ HRESULT SetSelectedForRestore([in] VSS_ID id, [in] VSS_COMPONENT_TYPE ct, [in] LPCWSTR path,
+ [in] LPCWSTR name, [in] BOOL selected_restore);
+ HRESULT SetRestoreOptions([in] VSS_ID id, [in] VSS_COMPONENT_TYPE ct, [in] LPCWSTR path, [in] LPCWSTR name,
+ [in] LPCWSTR options);
+ HRESULT SetAdditionalRestores([in] VSS_ID id, [in] VSS_COMPONENT_TYPE ct, [in] LPCWSTR path, [in] LPCWSTR name,
+ [in] BOOL additional);
+ HRESULT SetPreviousBackupStamp([in] VSS_ID id, [in] VSS_COMPONENT_TYPE ct, [in] LPCWSTR path, [in] LPCWSTR name,
+ [in] LPCWSTR stamp);
+ HRESULT SaveAsXML([in] BSTR *xml);
+ HRESULT BackupComplete([out] IVssAsync **async);
+ HRESULT AddAlternativeLocationMapping([in] VSS_ID id, [in] VSS_COMPONENT_TYPE type, [in] LPCWSTR logical,
+ [in] LPCWSTR name, [in] LPCWSTR path, [in] LPCWSTR filespec, [in] BOOL recursive, [in] LPCWSTR destination);
+ HRESULT AddRestoreSubcomponent([in] VSS_ID id, [in] VSS_COMPONENT_TYPE type, [in] LPCWSTR logical, [in] LPCWSTR name,
+ [in] LPCWSTR path, [in] LPCWSTR sub_name, [in] BOOL repair);
+ HRESULT SetFileRestoreStatus([in] VSS_ID id, [in] VSS_COMPONENT_TYPE ct, [in] LPCWSTR path, [in] LPCWSTR name,
+ [in] VSS_FILE_RESTORE_STATUS status);
+ HRESULT AddNewTarget([in] VSS_ID id, [in] VSS_COMPONENT_TYPE ct, [in] LPCWSTR logical, [in] LPCWSTR component,
+ [in] LPCWSTR path, [in] LPCWSTR filename, [in] BOOL recursive, [in] LPCWSTR alternate);
+ HRESULT SetRangesFilePath([in] VSS_ID id, [in] VSS_COMPONENT_TYPE ct, [in] LPCWSTR logical, [in] LPCWSTR component,
+ [in] UINT partial, [in] LPCWSTR ranges);
+ HRESULT PreRestore([out] IVssAsync **async);
+ HRESULT PostRestore([out] IVssAsync **async);
+ HRESULT SetContext([in] LONG context);
+ HRESULT StartSnapshotSet([out] VSS_ID *id);
+ HRESULT AddToSnapshotSet([in] VSS_PWSZ volume,[in] VSS_ID id,[out] VSS_ID *snapshot);
+ HRESULT DoSnapshotSet([out] IVssAsync ** async);
+ HRESULT DeleteSnapshots([in] VSS_ID object, [in] VSS_OBJECT_TYPE type, [in] BOOL force, [in] LONG *snapshots, [in] VSS_ID *id);
+ HRESULT ImportSnapshots([out] IVssAsync **async);
+ HRESULT BreakSnapshotSet([in] VSS_ID snapshot);
+ HRESULT GetSnapshotProperties([in] VSS_ID snapshot, [out] VSS_SNAPSHOT_PROP *prop);
+ HRESULT Query([in] VSS_ID queried, [in] VSS_OBJECT_TYPE queried_type, [in] VSS_OBJECT_TYPE returned_type, [in] IVssEnumObject **enums);
+ HRESULT IsVolumeSupported([in] VSS_ID provider, [in] VSS_PWSZ volume,[in] BOOL *supported);
+ HRESULT DisableWriterClasses([in] const VSS_ID *writer_id, [in] UINT class_id);
+ HRESULT EnableWriterClasses([in] const VSS_ID *classid, [in] UINT id);
+ HRESULT DisableWriterInstances([in] const VSS_ID *instance, [in] UINT id);
+ HRESULT ExposeSnapshot([in] VSS_ID snapshot, [in] VSS_PWSZ path, [in] LONG attributes,
+ [in] VSS_PWSZ expose, [out] VSS_PWSZ *exposed);
+ HRESULT RevertToSnapshot([in] VSS_ID snapshot, [in] BOOL force);
+ HRESULT QueryRevertStatus([in] VSS_PWSZ volume, [out] IVssAsync **async);
+};
--
1.9.1

View File

@ -1,71 +0,0 @@
From 3d0f1e5a448ac667c3d9f3bd9ca09e467fa53871 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Mon, 14 Jan 2019 12:18:26 +1100
Subject: [PATCH 5/6] vssapi: Add CreateVssBackupComponentsInternal stub
---
dlls/vssapi/main.c | 7 +++++++
dlls/vssapi/vssapi.spec | 2 +-
include/vsbackup.idl | 11 +++++++++++
3 files changed, 19 insertions(+), 1 deletion(-)
diff --git a/dlls/vssapi/main.c b/dlls/vssapi/main.c
index 9234544..a24b320 100644
--- a/dlls/vssapi/main.c
+++ b/dlls/vssapi/main.c
@@ -22,6 +22,7 @@
#include "winbase.h"
#include "vss.h"
#include "vswriter.h"
+#include "vsbackup.h"
#include "wine/debug.h"
WINE_DEFAULT_DEBUG_CHANNEL( vssapi );
@@ -107,3 +108,9 @@ HRESULT __thiscall VSSAPI_CVssWriter_Unsubscribe( struct CVssWriter *writer )
FIXME( "%p\n", writer );
return S_OK;
}
+
+HRESULT WINAPI CreateVssBackupComponentsInternal(IVssBackupComponents **backup)
+{
+ FIXME("%p\n", backup);
+ return E_NOTIMPL;
+}
diff --git a/dlls/vssapi/vssapi.spec b/dlls/vssapi/vssapi.spec
index 146feb4..7bd47e8 100644
--- a/dlls/vssapi/vssapi.spec
+++ b/dlls/vssapi/vssapi.spec
@@ -75,7 +75,7 @@
@ stub ?Uninitialize@CVssJetWriter@@QAGXXZ
@ thiscall -arch=i386 ?Unsubscribe@CVssWriter@@QAGJXZ(ptr) VSSAPI_CVssWriter_Unsubscribe
@ cdecl -arch=win64 ?Unsubscribe@CVssWriter@@QEAAJXZ(ptr) VSSAPI_CVssWriter_Unsubscribe
-@ stub CreateVssBackupComponentsInternal
+@ stdcall CreateVssBackupComponentsInternal(ptr)
@ stub CreateVssExamineWriterMetadataInternal
@ stub CreateVssExpressWriterInternal
@ stub CreateWriter
diff --git a/include/vsbackup.idl b/include/vsbackup.idl
index 0b5a2d3..e2f5a54 100644
--- a/include/vsbackup.idl
+++ b/include/vsbackup.idl
@@ -25,6 +25,17 @@ interface IVssEnumObject;
interface IVssExamineWriterMetadata;
interface IVssWriterComponentsExt;
+cpp_quote("#ifdef _cplusplus")
+cpp_quote("extern \"C\" {")
+cpp_quote("#endif")
+cpp_quote("HRESULT WINAPI CreateVssBackupComponentsInternal(IVssBackupComponents **backup);")
+cpp_quote("#ifdef _cplusplus")
+cpp_quote("}")
+cpp_quote("#endif")
+
+cpp_quote("static inline HRESULT CreateVssBackupComponents(IVssBackupComponents **backup)")
+cpp_quote(" { return CreateVssBackupComponentsInternal(backup); }")
+
[
uuid("665c1d5f-c218-414d-a05d-7fef5f9d5c86"),
local
--
1.9.1

View File

@ -1,45 +0,0 @@
From 2672c7b782026df87cd3007c8006811f021d4545 Mon Sep 17 00:00:00 2001
From: Alistair Leslie-Hughes <leslie_alistair@hotmail.com>
Date: Tue, 15 Jan 2019 10:38:28 +1100
Subject: [PATCH 6/6] vssapi: Add
?CreateVssBackupComponents@@YGJPAPAVIVssBackupComponents@@@Z stub
---
dlls/vssapi/main.c | 10 ++++++++++
dlls/vssapi/vssapi.spec | 2 +-
2 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/dlls/vssapi/main.c b/dlls/vssapi/main.c
index a24b320..7617c0d 100644
--- a/dlls/vssapi/main.c
+++ b/dlls/vssapi/main.c
@@ -114,3 +114,13 @@ HRESULT WINAPI CreateVssBackupComponentsInternal(IVssBackupComponents **backup)
FIXME("%p\n", backup);
return E_NOTIMPL;
}
+
+/******************************************************************
+ * ?CreateVssBackupComponents@@YGJPAPAVIVssBackupComponents@@@Z
+ */
+HRESULT VSSAPI_CreateVssBackupComponents( IVssBackupComponents **backup )
+{
+ FIXME( "%p\n", backup );
+
+ return CreateVssBackupComponentsInternal(backup);
+}
diff --git a/dlls/vssapi/vssapi.spec b/dlls/vssapi/vssapi.spec
index 7bd47e8..c759c11 100644
--- a/dlls/vssapi/vssapi.spec
+++ b/dlls/vssapi/vssapi.spec
@@ -9,7 +9,7 @@
@ cdecl -arch=win64 ??1CVssWriter@@UEAA@XZ(ptr) VSSAPI_CVssWriter_dtor
@ stub ?AreComponentsSelected@CVssJetWriter@@IBG_NXZ
@ stub ?AreComponentsSelected@CVssWriter@@IBG_NXZ
-@ stub ?CreateVssBackupComponents@@YGJPAPAVIVssBackupComponents@@@Z
+@ stdcall ?CreateVssBackupComponents@@YGJPAPAVIVssBackupComponents@@@Z(ptr) VSSAPI_CreateVssBackupComponents
@ stub ?CreateVssExamineWriterMetadata@@YGJPAGPAPAVIVssExamineWriterMetadata@@@Z
@ stub ?CreateVssSnapshotSetDescription@@YGJU_GUID@@JPAPAVIVssSnapshotSetDescription@@@Z
@ stub ?GetBackupType@CVssJetWriter@@IBG?AW4_VSS_BACKUP_TYPE@@XZ
--
1.9.1

View File

@ -1,2 +0,0 @@
Fixes: [37639] vssapi: Add ?CreateVssBackupComponents@@YGJPAPAVIVssBackupComponents@ stub
Fixes: [46088] vssapi: Add CreateVssBackupComponentsInternal stub

View File

@ -1,46 +0,0 @@
From 54d8899aa04476bc279b6551ce3ed04cf4461e0b Mon Sep 17 00:00:00 2001
From: Paul Gofman <gofmanp@gmail.com>
Date: Tue, 22 Jan 2019 17:03:14 +0300
Subject: [PATCH] wined3d: Return stream frequency of 1 if it was not set.
Wine-bug: https://bugs.winehq.org/show_bug.cgi?id=39080
Signed-off-by: Paul Gofman <gofmanp@gmail.com>
---
dlls/d3d9/tests/visual.c | 7 +++++++
dlls/wined3d/device.c | 2 +-
2 files changed, 8 insertions(+), 1 deletion(-)
diff --git a/dlls/d3d9/tests/visual.c b/dlls/d3d9/tests/visual.c
index fb1c7ef21d..7278051ddc 100644
--- a/dlls/d3d9/tests/visual.c
+++ b/dlls/d3d9/tests/visual.c
@@ -12416,6 +12416,13 @@ static void stream_test(void)
goto done;
}
+ hr = IDirect3DDevice9_GetStreamSourceFreq(device, 0, &ind);
+ ok(hr == D3D_OK && ind == 1, "IDirect3DDevice9_GetStreamSourceFreq unexpected result,"
+ " hr %08x, ind %U.\n", hr, ind);
+ hr = IDirect3DDevice9_GetStreamSourceFreq(device, 1, &ind);
+ ok(hr == D3D_OK && ind == 1, "IDirect3DDevice9_GetStreamSourceFreq unexpected result,"
+ " hr %08x, ind %U.\n", hr, ind);
+
/* set the default value because it isn't done in wine? */
hr = IDirect3DDevice9_SetStreamSourceFreq(device, 1, 1);
ok(hr == D3D_OK, "IDirect3DDevice9_SetStreamSourceFreq failed with %08x\n", hr);
diff --git a/dlls/wined3d/device.c b/dlls/wined3d/device.c
index 9fa27f65e5..0f1406c90b 100644
--- a/dlls/wined3d/device.c
+++ b/dlls/wined3d/device.c
@@ -1476,7 +1476,7 @@ HRESULT CDECL wined3d_device_get_stream_source_freq(const struct wined3d_device
TRACE("device %p, stream_idx %u, divider %p.\n", device, stream_idx, divider);
stream = &device->state.streams[stream_idx];
- *divider = stream->flags | stream->frequency;
+ *divider = stream->flags | (stream->frequency || stream->flags ? stream->frequency : 1);
TRACE("Returning %#x.\n", *divider);
--
2.20.1

View File

@ -1 +0,0 @@
Fixes: [39080] wined3d: Return stream frequency of 1 if it was not set.