Wine-Devel
By thread
wine-devel@list.winehq.org
By month
Messages by month
- ----- 2026 -----
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2005 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2004 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2003 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2002 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2001 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
March 2019
- 76 participants
- 2386 messages
[PATCH] l3codeca.acm: Check input format in MPEG3_StreamOpen.
by Vijay Kiran Kamuju
Add comments on a test which crashes on XP, Vista
Modify broken test for Win 8
From: Michael Müller <michael(a)fds-team.de>
Signed-off-by: Vijay Kiran Kamuju <infyquest(a)gmail.com>
---
dlls/l3codeca.acm/mpegl3.c | 15 ++++++-
dlls/msacm32/tests/msacm.c | 83 ++++++++++++++++++++++++++++++++++++++
2 files changed, 97 insertions(+), 1 deletion(-)
diff --git a/dlls/l3codeca.acm/mpegl3.c b/dlls/l3codeca.acm/mpegl3.c
index 8ad6ae83dc..2e929371ae 100644
--- a/dlls/l3codeca.acm/mpegl3.c
+++ b/dlls/l3codeca.acm/mpegl3.c
@@ -212,6 +212,7 @@ static void MPEG3_Reset(PACMDRVSTREAMINSTANCE adsi, AcmMpeg3Data* aad)
*/
static LRESULT MPEG3_StreamOpen(PACMDRVSTREAMINSTANCE adsi)
{
+ LRESULT error = MMSYSERR_NOTSUPPORTED;
AcmMpeg3Data* aad;
int err;
@@ -235,6 +236,18 @@ static LRESULT MPEG3_StreamOpen(PACMDRVSTREAMINSTANCE adsi)
adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_MPEG) &&
adsi->pwfxDst->wFormatTag == WAVE_FORMAT_PCM)
{
+ if (adsi->pwfxSrc->wFormatTag == WAVE_FORMAT_MPEGLAYER3)
+ {
+ MPEGLAYER3WAVEFORMAT *formatmp3 = (MPEGLAYER3WAVEFORMAT *)adsi->pwfxSrc;
+
+ if (adsi->pwfxSrc->cbSize < MPEGLAYER3_WFX_EXTRA_BYTES ||
+ formatmp3->wID != MPEGLAYER3_ID_MPEG)
+ {
+ error = ACMERR_NOTPOSSIBLE;
+ goto theEnd;
+ }
+ }
+
/* resampling or mono <=> stereo not available
* MPEG3 algo only define 16 bit per sample output
*/
@@ -270,7 +283,7 @@ static LRESULT MPEG3_StreamOpen(PACMDRVSTREAMINSTANCE adsi)
theEnd:
HeapFree(GetProcessHeap(), 0, aad);
adsi->dwDriver = 0L;
- return MMSYSERR_NOTSUPPORTED;
+ return error;
}
/***********************************************************************
diff --git a/dlls/msacm32/tests/msacm.c b/dlls/msacm32/tests/msacm.c
index 180639fa54..a6b17e8441 100644
--- a/dlls/msacm32/tests/msacm.c
+++ b/dlls/msacm32/tests/msacm.c
@@ -1276,6 +1276,88 @@ static void test_acmFormatChoose(void)
HeapFree(GetProcessHeap(), 0, pwfx);
}
+static void test_mp3(void)
+{
+ MPEGLAYER3WAVEFORMAT src;
+ WAVEFORMATEX dst;
+ HACMSTREAM has;
+ DWORD output;
+ MMRESULT mr;
+
+ src.wfx.wFormatTag = WAVE_FORMAT_MPEGLAYER3;
+ src.wfx.nSamplesPerSec = 11025;
+ src.wfx.wBitsPerSample = 0;
+ src.wfx.nChannels = 1;
+ src.wfx.nBlockAlign = 576;
+ src.wfx.nAvgBytesPerSec = 2000;
+
+ src.wID = MPEGLAYER3_ID_MPEG;
+ src.fdwFlags = 0;
+ src.nBlockSize = 576;
+ src.nFramesPerBlock = 1;
+ src.nCodecDelay = 0;
+
+ dst.cbSize = 0;
+ dst.wFormatTag = WAVE_FORMAT_PCM;
+ dst.nSamplesPerSec = 11025;
+ dst.wBitsPerSample = 16;
+ dst.nChannels = 1;
+ dst.nBlockAlign = dst.wBitsPerSample * dst.nChannels / 8;
+ dst.nAvgBytesPerSec = dst.nSamplesPerSec * dst.nBlockAlign;
+
+ src.wfx.cbSize = 0;
+
+ mr = acmStreamOpen(&has, NULL, (WAVEFORMATEX*)&src, &dst, NULL, 0, 0, 0);
+ ok(mr == ACMERR_NOTPOSSIBLE, "expected error ACMERR_NOTPOSSIBLE, got 0x%x\n", mr);
+ if (mr == MMSYSERR_NOERROR) acmStreamClose(has, 0);
+
+ src.wfx.cbSize = MPEGLAYER3_WFX_EXTRA_BYTES;
+ src.wID = 0;
+
+ mr = acmStreamOpen(&has, NULL, (WAVEFORMATEX*)&src, &dst, NULL, 0, 0, 0);
+ ok(mr == ACMERR_NOTPOSSIBLE, "expected error ACMERR_NOTPOSSIBLE, got 0x%x\n", mr);
+ if (mr == MMSYSERR_NOERROR) acmStreamClose(has, 0);
+
+ src.wID = MPEGLAYER3_ID_MPEG;
+ src.nBlockSize = 0;
+
+ mr = acmStreamOpen(&has, NULL, (WAVEFORMATEX*)&src, &dst, NULL, 0, 0, 0);
+ ok(mr == MMSYSERR_NOERROR || broken(mr == ACMERR_NOTPOSSIBLE) /* Win 2008 */,
+ "failed with error 0x%x\n", mr);
+ if (mr == MMSYSERR_NOERROR)
+ {
+ mr = acmStreamClose(has, 0);
+ ok(mr == MMSYSERR_NOERROR, "failed with error 0x%x\n", mr);
+ }
+ src.nBlockSize = 576;
+ src.wfx.nAvgBytesPerSec = 0;
+
+ mr = acmStreamOpen(&has, NULL, (WAVEFORMATEX*)&src, &dst, NULL, 0, 0, 0);
+ ok(mr == MMSYSERR_NOERROR || broken(mr == ACMERR_NOTPOSSIBLE) /* Win 2008 */,
+ "failed with error 0x%x\n", mr);
+ if (mr == MMSYSERR_NOERROR)
+ {
+ /* causes a division by zero exception in XP, Vista,
+ but throws ACMERR_NOTPOSSIBLE on others */
+ if (0) acmStreamSize(has, 4000, &output, ACM_STREAMSIZEF_SOURCE);
+ mr = acmStreamClose(has, 0);
+ ok(mr == MMSYSERR_NOERROR, "failed with error 0x%x\n", mr);
+ }
+
+ src.wfx.nAvgBytesPerSec = 2000;
+
+ mr = acmStreamOpen(&has, NULL, (WAVEFORMATEX*)&src, &dst, NULL, 0, 0, 0);
+ ok(mr == MMSYSERR_NOERROR || broken(mr == ACMERR_NOTPOSSIBLE) /* Win 2008 */,
+ "failed with error 0x%x\n", mr);
+ if (mr == MMSYSERR_NOERROR)
+ {
+ mr = acmStreamSize(has, 4000, &output, ACM_STREAMSIZEF_SOURCE);
+ ok(mr == MMSYSERR_NOERROR, "failed with error 0x%x\n", mr);
+ mr = acmStreamClose(has, 0);
+ ok(mr == MMSYSERR_NOERROR, "failed with error 0x%x\n", mr);
+ }
+}
+
static struct
{
struct
@@ -1446,6 +1528,7 @@ START_TEST(msacm)
test_acmFormatSuggest();
test_acmFormatTagDetails();
test_acmFormatChoose();
+ test_mp3();
/* Test acmDriverAdd in the end as it may conflict
* with other tests due to codec lookup order */
test_acmDriverAdd();
--
2.21.0
March 31, 2019
[resend] sxs: Implement SxsLookupClrGuid and add tests
by Fabian Maurer
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=43270
Signed-off-by: Fabian Maurer <dark.shadow4(a)web.de>
---
dlls/sxs/sxs.c | 148 ++++++++++++++++++
dlls/sxs/sxs.spec | 1 +
dlls/sxs/tests/Makefile.in | 8 +-
dlls/sxs/tests/comtest_dll.manifest | 16 ++
dlls/sxs/tests/comtest_exe.manifest | 11 ++
dlls/sxs/tests/interfaces.idl | 33 ++++
dlls/sxs/tests/resource.rc | 27 ++++
dlls/sxs/tests/sxs.c | 223 ++++++++++++++++++++++++++++
8 files changed, 465 insertions(+), 2 deletions(-)
create mode 100644 dlls/sxs/tests/comtest_dll.manifest
create mode 100644 dlls/sxs/tests/comtest_exe.manifest
create mode 100644 dlls/sxs/tests/interfaces.idl
create mode 100644 dlls/sxs/tests/resource.rc
create mode 100644 dlls/sxs/tests/sxs.c
diff --git a/dlls/sxs/sxs.c b/dlls/sxs/sxs.c
index 06e6672dbf..7eec772de1 100644
--- a/dlls/sxs/sxs.c
+++ b/dlls/sxs/sxs.c
@@ -23,6 +23,10 @@
#include "windef.h"
#include "winbase.h"
+#include "wine/heap.h"
+#include "wine/debug.h"
+
+WINE_DEFAULT_DEBUG_CHANNEL(sxs);
/***********************************************************************
* DllMain (SXS.@)
@@ -40,3 +44,147 @@ BOOL WINAPI DllMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID lpvReserved)
}
return TRUE;
}
+
+typedef struct _SXS_GUID_INFORMATION_CLR
+{
+ DWORD cbSize;
+ DWORD dwFlags;
+ PCWSTR pcwszRuntimeVersion;
+ PCWSTR pcwszTypeName;
+ PCWSTR pcwszAssemblyIdentity;
+} SXS_GUID_INFORMATION_CLR, *PSXS_GUID_INFORMATION_CLR;
+
+#define SXS_GUID_INFORMATION_CLR_FLAG_IS_SURROGATE 0x1
+#define SXS_GUID_INFORMATION_CLR_FLAG_IS_CLASS 0x2
+
+#define SXS_LOOKUP_CLR_GUID_USE_ACTCTX 0x00000001
+#define SXS_LOOKUP_CLR_GUID_FIND_SURROGATE 0x00010000
+#define SXS_LOOKUP_CLR_GUID_FIND_CLR_CLASS 0x00020000
+
+struct comclassredirect_data
+{
+ ULONG size;
+ BYTE res;
+ BYTE miscmask;
+ BYTE res1[2];
+ DWORD model;
+ GUID clsid;
+ GUID alias;
+ GUID clsid2;
+ GUID tlbid;
+ ULONG name_len;
+ ULONG name_offset;
+ ULONG progid_len;
+ ULONG progid_offset;
+ ULONG clrdata_len;
+ ULONG clrdata_offset;
+ DWORD miscstatus;
+ DWORD miscstatuscontent;
+ DWORD miscstatusthumbnail;
+ DWORD miscstatusicon;
+ DWORD miscstatusdocprint;
+};
+
+struct clrclass_data
+{
+ ULONG size;
+ DWORD res[2];
+ ULONG module_len;
+ ULONG module_offset;
+ ULONG name_len;
+ ULONG name_offset;
+ ULONG version_len;
+ ULONG version_offset;
+ DWORD res2[2];
+};
+
+BOOL WINAPI SxsLookupClrGuid(DWORD flags, GUID *clsid, HANDLE actctx, void *buffer, SIZE_T buffer_len, SIZE_T *buffer_len_required)
+{
+ ACTCTX_SECTION_KEYED_DATA guid_info = { sizeof(ACTCTX_SECTION_KEYED_DATA) };
+ ACTIVATION_CONTEXT_ASSEMBLY_DETAILED_INFORMATION *assembly_info;
+ SIZE_T bytes_assembly_info;
+ struct comclassredirect_data *redirect_data;
+ struct clrclass_data *class_data;
+ int len_version = 0, len_name, len_identity;
+ const void *ptr_name, *ptr_version, *ptr_identity;
+ SXS_GUID_INFORMATION_CLR *ret = buffer;
+ char *ret_strings;
+
+ TRACE("(%x, %s, %p, %p, %08lx, %p): stub\n", flags, wine_dbgstr_guid(clsid), actctx, buffer, buffer_len, buffer_len_required);
+
+ if (flags & (~SXS_LOOKUP_CLR_GUID_FIND_CLR_CLASS))
+ FIXME("Ignored flags: %x\n", flags & (~SXS_LOOKUP_CLR_GUID_FIND_CLR_CLASS));
+
+ if (!FindActCtxSectionGuid(FIND_ACTCTX_SECTION_KEY_RETURN_HACTCTX, 0, ACTIVATION_CONTEXT_SECTION_COM_SERVER_REDIRECTION, clsid, &guid_info))
+ {
+ SetLastError(ERROR_NOT_FOUND);
+ return FALSE;
+ }
+
+ QueryActCtxW(0, guid_info.hActCtx, &guid_info.ulAssemblyRosterIndex,
+ AssemblyDetailedInformationInActivationContext, NULL, 0, &bytes_assembly_info);
+ if (GetLastError() != ERROR_INSUFFICIENT_BUFFER)
+ {
+ ERR("QueryActCtxW failed: %d!\n", GetLastError());
+ ReleaseActCtx(guid_info.hActCtx);
+ return FALSE;
+ }
+ assembly_info = heap_alloc(bytes_assembly_info);
+ if(!QueryActCtxW(0, guid_info.hActCtx, &guid_info.ulAssemblyRosterIndex,
+ AssemblyDetailedInformationInActivationContext, assembly_info, bytes_assembly_info, &bytes_assembly_info))
+ {
+ ERR("QueryActCtxW failed: %d!\n", GetLastError());
+ heap_free(assembly_info);
+ ReleaseActCtx(guid_info.hActCtx);
+ return FALSE;
+ }
+
+ redirect_data = guid_info.lpData;
+ class_data = (void *)((char*)redirect_data + redirect_data->clrdata_offset);
+
+ ptr_identity = assembly_info->lpAssemblyEncodedAssemblyIdentity;
+ ptr_name = (char *)class_data + class_data->name_offset;
+ ptr_version = (char *)class_data + class_data->version_offset;
+
+ len_identity = assembly_info->ulEncodedAssemblyIdentityLength + sizeof(WCHAR);
+ len_name = class_data->name_len + sizeof(WCHAR);
+ if (class_data->version_len > 0)
+ len_version = class_data->version_len + sizeof(WCHAR);
+
+ *buffer_len_required = sizeof(SXS_GUID_INFORMATION_CLR) + len_identity + len_version + len_name;
+ if (!buffer || buffer_len < *buffer_len_required)
+ {
+ SetLastError(ERROR_INSUFFICIENT_BUFFER);
+ heap_free(assembly_info);
+ ReleaseActCtx(guid_info.hActCtx);
+ return FALSE;
+ }
+
+ ret->cbSize = sizeof(SXS_GUID_INFORMATION_CLR);
+ ret->dwFlags = SXS_GUID_INFORMATION_CLR_FLAG_IS_CLASS;
+
+ /* Copy strings into buffer */
+ ret_strings = (char *)ret + sizeof(SXS_GUID_INFORMATION_CLR);
+
+ memcpy(ret_strings, ptr_identity, len_identity);
+ ret->pcwszAssemblyIdentity = (WCHAR *)ret_strings;
+ ret_strings += len_identity;
+
+ memcpy(ret_strings, ptr_name, len_name);
+ ret->pcwszTypeName = (WCHAR *)ret_strings;
+ ret_strings += len_name;
+
+ if (len_version > 0)
+ {
+ memcpy(ret_strings, ptr_version, len_version);
+ ret->pcwszRuntimeVersion = (WCHAR *)ret_strings;
+ }
+ else
+ ret->pcwszRuntimeVersion = NULL;
+
+ SetLastError(0);
+
+ ReleaseActCtx(guid_info.hActCtx);
+ heap_free(assembly_info);
+ return TRUE;
+}
diff --git a/dlls/sxs/sxs.spec b/dlls/sxs/sxs.spec
index 2a27313427..138d68f7d7 100644
--- a/dlls/sxs/sxs.spec
+++ b/dlls/sxs/sxs.spec
@@ -1,2 +1,3 @@
@ stdcall CreateAssemblyCache(ptr long)
@ stdcall CreateAssemblyNameObject(ptr wstr long ptr)
+@ stdcall SxsLookupClrGuid(long ptr ptr ptr long ptr)
diff --git a/dlls/sxs/tests/Makefile.in b/dlls/sxs/tests/Makefile.in
index 34609a14ae..46b5485d29 100644
--- a/dlls/sxs/tests/Makefile.in
+++ b/dlls/sxs/tests/Makefile.in
@@ -1,6 +1,10 @@
TESTDLL = sxs.dll
-IMPORTS = sxs
+IMPORTS = sxs shlwapi
C_SRCS = \
cache.c \
- name.c
+ name.c \
+ sxs.c
+
+RC_SRCS = resource.rc
+IDL_SRCS = interfaces.idl
\ No newline at end of file
diff --git a/dlls/sxs/tests/comtest_dll.manifest b/dlls/sxs/tests/comtest_dll.manifest
new file mode 100644
index 0000000000..ef6924de9e
--- /dev/null
+++ b/dlls/sxs/tests/comtest_dll.manifest
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
+ <assemblyIdentity
+ name="comtest"
+ version="1.0.0.0"
+ type="win32"
+ />
+ <clrClass
+ clsid="{2e106e50-e7a4-4489-8538-83643f100fdc}"
+ threadingModel="Both"
+ name="DLL.Test"
+ runtimeVersion="v4.0.0.0">
+ </clrClass>
+ <file name="comtest.dll">
+ </file>
+</assembly>
diff --git a/dlls/sxs/tests/comtest_exe.manifest b/dlls/sxs/tests/comtest_exe.manifest
new file mode 100644
index 0000000000..bc9ce4c045
--- /dev/null
+++ b/dlls/sxs/tests/comtest_exe.manifest
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
+<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
+ <dependency>
+ <dependentAssembly>
+ <assemblyIdentity
+ name="comtest"
+ version="1.0.0.0"
+ type="win32"/>
+ </dependentAssembly>
+ </dependency>
+</assembly>
diff --git a/dlls/sxs/tests/interfaces.idl b/dlls/sxs/tests/interfaces.idl
new file mode 100644
index 0000000000..9e64988197
--- /dev/null
+++ b/dlls/sxs/tests/interfaces.idl
@@ -0,0 +1,33 @@
+/*
+ * Copyright 2018 Fabian Maurer
+ *
+ * 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
+ */
+
+#include "unknwn.idl"
+
+[
+ object,
+ uuid(1dbc4491-080d-45c5-a15d-1e3c4610bdd9),
+ local
+]
+interface ITest : IUnknown {
+ HRESULT Func([in, out] int *i);
+};
+
+[
+ uuid(2e106e50-e7a4-4489-8538-83643f100fdc),
+]
+coclass Test { interface ITest; };
diff --git a/dlls/sxs/tests/resource.rc b/dlls/sxs/tests/resource.rc
new file mode 100644
index 0000000000..dd2c25bf37
--- /dev/null
+++ b/dlls/sxs/tests/resource.rc
@@ -0,0 +1,27 @@
+/*
+ * Resources for sxs test suite.
+ *
+ * Copyright 2018 Fabian Maurer
+ *
+ * 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
+ */
+
+#include "windef.h"
+
+/* @makedep: comtest_exe.manifest */
+comtest_exe.manifest RCDATA comtest_exe.manifest
+
+/* @makedep: comtest_dll.manifest */
+comtest_dll.manifest RCDATA comtest_dll.manifest
diff --git a/dlls/sxs/tests/sxs.c b/dlls/sxs/tests/sxs.c
new file mode 100644
index 0000000000..d92bfb65c1
--- /dev/null
+++ b/dlls/sxs/tests/sxs.c
@@ -0,0 +1,223 @@
+/*
+ * Copyright 2018 Fabian Maurer
+ *
+ * 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
+ */
+
+#include <stdio.h>
+
+#define COBJMACROS
+
+#include <windows.h>
+#include <winsxs.h>
+#include <corerror.h>
+#include "shlwapi.h"
+
+#include "wine/test.h"
+#include "wine/heap.h"
+
+#include "initguid.h"
+#include "interfaces.h"
+
+BOOL (WINAPI *pSxsLookupClrGuid)(DWORD flags, GUID *clsid, HANDLE actctx, void *buffer, SIZE_T buffer_len, SIZE_T *buffer_len_required);
+
+#define SXS_LOOKUP_CLR_GUID_USE_ACTCTX 0x00000001
+#define SXS_LOOKUP_CLR_GUID_FIND_SURROGATE 0x00010000
+#define SXS_LOOKUP_CLR_GUID_FIND_CLR_CLASS 0x00020000
+#define SXS_LOOKUP_CLR_GUID_FIND_ANY (SXS_LOOKUP_CLR_GUID_FIND_SURROGATE | SXS_LOOKUP_CLR_GUID_FIND_CLR_CLASS)
+
+#define SXS_GUID_INFORMATION_CLR_FLAG_IS_SURROGATE 0x00000001
+#define SXS_GUID_INFORMATION_CLR_FLAG_IS_CLASS 0x00000002
+
+typedef struct _SXS_GUID_INFORMATION_CLR
+{
+ DWORD cbSize;
+ DWORD dwFlags;
+ PCWSTR pcwszRuntimeVersion;
+ PCWSTR pcwszTypeName;
+ PCWSTR pcwszAssemblyIdentity;
+} SXS_GUID_INFORMATION_CLR;
+
+static BOOL write_resource_file(const char *path_tmp, const char *name_res, const char *name_file, char *path_file)
+{
+ HRSRC rsrc;
+ void *rsrc_data;
+ DWORD rsrc_size;
+ BOOL ret;
+ HANDLE hfile;
+
+ rsrc = FindResourceA(GetModuleHandleA(NULL), name_res, (LPCSTR)RT_RCDATA);
+ if (!rsrc) return FALSE;
+
+ rsrc_data = LockResource(LoadResource(GetModuleHandleA(NULL), rsrc));
+ if (!rsrc_data) return FALSE;
+
+ rsrc_size = SizeofResource(GetModuleHandleA(NULL), rsrc);
+ if (!rsrc_size) return FALSE;
+
+ strcpy(path_file, path_tmp);
+ PathAppendA(path_file, name_file);
+ hfile = CreateFileA(path_file, GENERIC_WRITE, 0, NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, 0);
+ if (hfile == INVALID_HANDLE_VALUE) return FALSE;
+
+ ret = WriteFile(hfile, rsrc_data, rsrc_size, &rsrc_size, NULL);
+
+ CloseHandle(hfile);
+ return ret;
+}
+
+static void run_test(void)
+{
+ SIZE_T buffer_size;
+ BOOL ret;
+ SXS_GUID_INFORMATION_CLR *info;
+ WCHAR expected_type_name[] = {'D','L','L','.','T','e','s','t',0};
+ WCHAR expected_runtime_version[] = {'v','4','.','0','.','0','.','0',0};
+ WCHAR expected_assembly_identity[] = {'c','o','m','t','e','s','t',',','t','y','p','e','=','"','w','i','n','3','2','"',',','v','e','r','s','i','o','n','=','"','1','.','0','.','0','.','0','"',0};
+
+ ret = pSxsLookupClrGuid(SXS_LOOKUP_CLR_GUID_FIND_CLR_CLASS, (GUID*)&CLSID_Test, NULL, NULL, 0, &buffer_size);
+ ok(ret == FALSE, "Got %d\n", ret);
+ ok(GetLastError() == ERROR_INSUFFICIENT_BUFFER, "Got %d\n", GetLastError());
+
+ info = heap_alloc(buffer_size);
+ ret = pSxsLookupClrGuid(SXS_LOOKUP_CLR_GUID_FIND_CLR_CLASS, (GUID*)&CLSID_Test, NULL, info, buffer_size, &buffer_size);
+ ok(ret == TRUE, "Got %d\n", ret);
+ ok(GetLastError() == 0, "Got %d\n", GetLastError());
+
+ ok(info->dwFlags == SXS_GUID_INFORMATION_CLR_FLAG_IS_CLASS, "Got %d\n", info->dwFlags);
+ ok(lstrcmpW(info->pcwszTypeName, expected_type_name) == 0, "Got %s\n", wine_dbgstr_w(info->pcwszTypeName));
+ ok(lstrcmpW(info->pcwszAssemblyIdentity, expected_assembly_identity) == 0, "Got %s\n", wine_dbgstr_w(info->pcwszAssemblyIdentity));
+ ok(lstrcmpW(info->pcwszRuntimeVersion, expected_runtime_version) == 0, "Got %s\n", wine_dbgstr_w(info->pcwszRuntimeVersion));
+
+ heap_free(info);
+}
+
+static void prepare_and_run_test(void)
+{
+ char path_tmp[MAX_PATH] = {0};
+ char path_manifest_dll[MAX_PATH] = {0};
+ char path_manifest_exe[MAX_PATH] = {0};
+ BOOL success;
+ ACTCTXA context = {0};
+ ULONG_PTR cookie;
+ HANDLE handle_context = 0;
+
+ GetTempPathA(MAX_PATH, path_tmp);
+
+ if (!write_resource_file(path_tmp, "comtest_exe.manifest", "exe.manifest", path_manifest_exe))
+ {
+ ok(0, "Failed to create file for testing\n");
+ goto cleanup;
+ }
+
+ if (!write_resource_file(path_tmp, "comtest_dll.manifest", "comtest.manifest", path_manifest_dll))
+ {
+ ok(0, "Failed to create file for testing\n");
+ goto cleanup;
+ }
+
+ context.cbSize = sizeof(ACTCTXA);
+ context.lpSource = path_manifest_exe;
+ context.lpAssemblyDirectory = path_tmp;
+ context.dwFlags = ACTCTX_FLAG_ASSEMBLY_DIRECTORY_VALID;
+
+ handle_context = CreateActCtxA(&context);
+ ok(handle_context != NULL && handle_context != INVALID_HANDLE_VALUE, "CreateActCtxA failed: %d\n", GetLastError());
+
+ if (handle_context == NULL || handle_context == INVALID_HANDLE_VALUE)
+ {
+ ok(0, "Failed to create activation context\n");
+ goto cleanup;
+ }
+
+ success = ActivateActCtx(handle_context, &cookie);
+ ok(success, "ActivateActCtx failed: %d\n", GetLastError());
+
+ run_test();
+
+cleanup:
+ if (handle_context != NULL && handle_context != INVALID_HANDLE_VALUE)
+ {
+ success = DeactivateActCtx(0, cookie);
+ ok(success, "DeactivateActCtx failed: %d\n", GetLastError());
+ ReleaseActCtx(handle_context);
+ }
+ if (*path_manifest_exe)
+ {
+ success = DeleteFileA(path_manifest_exe);
+ ok(success, "DeleteFileA failed: %d\n", GetLastError());
+ }
+ if(*path_manifest_dll)
+ {
+ success = DeleteFileA(path_manifest_dll);
+ ok(success, "DeleteFileA failed: %d\n", GetLastError());
+ }
+}
+
+static void run_child_process(void)
+{
+ char cmdline[MAX_PATH];
+ char exe[MAX_PATH];
+ char **argv;
+ PROCESS_INFORMATION pi;
+ STARTUPINFOA si = { 0 };
+ BOOL ret;
+
+ winetest_get_mainargs(&argv);
+
+ if (strstr(argv[0], ".exe"))
+ sprintf(exe, "%s", argv[0]);
+ else
+ sprintf(exe, "%s.exe", argv[0]);
+ sprintf(cmdline, "\"%s\" %s %s", argv[0], argv[1], "subtest");
+
+ si.cb = sizeof(si);
+ ret = CreateProcessA(exe, cmdline, NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi);
+ ok(ret, "Could not create process: %u\n", GetLastError());
+
+ winetest_wait_child_process(pi.hProcess);
+
+ CloseHandle(pi.hThread);
+ CloseHandle(pi.hProcess);
+}
+
+static void test_SxsLookupClrGuid(void)
+{
+ SIZE_T buffer_size;
+ BOOL ret;
+
+ ret = pSxsLookupClrGuid(SXS_LOOKUP_CLR_GUID_FIND_CLR_CLASS, (GUID*)&CLSID_Test, NULL, NULL, 0, &buffer_size);
+ ok(ret == FALSE, "Expected FALSE, got %d\n", ret);
+ ok(GetLastError() == ERROR_NOT_FOUND, "Expected ERROR_NOT_FOUND, got %d\n", GetLastError());
+
+ run_child_process();
+}
+
+START_TEST(sxs)
+{
+ int argc;
+ char **argv;
+
+ pSxsLookupClrGuid = (void *)GetProcAddress(LoadLibraryA("sxs.dll"), "SxsLookupClrGuid");
+
+ argc = winetest_get_mainargs(&argv);
+ if (argc > 2)
+ {
+ prepare_and_run_test();
+ return;
+ }
+
+ test_SxsLookupClrGuid();
+}
--
2.21.0
March 31, 2019
[PATCH v2] include: add missing tags and defines in mmreg.h
by Vijay Kiran Kamuju
From: Vijay Kiran Kamuju <infyquest(a)gmail.com>
Signed-off-by: Vijay Kiran Kamuju <infyquest(a)gmail.com>
---
include/mmreg.h | 78 ++++++++++++++++++++++++++++++++++++++++++++--
include/mmsystem.h | 4 +--
2 files changed, 78 insertions(+), 4 deletions(-)
diff --git a/include/mmreg.h b/include/mmreg.h
index e7d70bbd63..8f4e4cb45b 100644
--- a/include/mmreg.h
+++ b/include/mmreg.h
@@ -75,6 +75,21 @@ typedef struct _WAVEFORMATEX {
} WAVEFORMATEX, *PWAVEFORMATEX, *NPWAVEFORMATEX, *LPWAVEFORMATEX;
#endif /* _WAVEFORMATEX_ */
+#ifndef WAVE_FORMAT_PCM
+typedef struct waveformat_tag {
+ WORD wFormatTag;
+ WORD nChannels;
+ DWORD nSamplesPerSec;
+ DWORD nAvgBytesPerSec;
+ WORD nBlockAlign;
+} WAVEFORMAT, *PWAVEFORMAT, *NPWAVEFORMAT, *LPWAVEFORMAT;
+
+typedef struct pcmwaveformat_tag {
+ WAVEFORMAT wf;
+ WORD wBitsPerSample;
+} PCMWAVEFORMAT, *PPCMWAVEFORMAT, *NPPCMWAVEFORMAT, *LPPCMWAVEFORMAT;
+#endif /* WAVE_FORMAT_PCM */
+
/* WAVE form wFormatTag IDs */
#define WAVE_FORMAT_UNKNOWN 0x0000 /* Microsoft Corporation */
#ifndef WAVE_FORMAT_PCM
@@ -117,6 +132,8 @@ typedef struct _WAVEFORMATEX {
#define WAVE_FORMAT_MPEGLAYER3 0x0055
#define WAVE_FORMAT_MSRT24 0x0082 /* Microsoft Corporation */
#define WAVE_FORMAT_DOLBY_AC3_SPDIF 0x0092
+#define WAVE_FORMAT_RAW_AAC1 0x00FF
+#define WAVE_FORMAT_MSAUDIO1 0x0160
#define WAVE_FORMAT_WMAUDIO2 0x0161
#define WAVE_FORMAT_WMAUDIO3 0x0162
#define WAVE_FORMAT_WMAUDIO_LOSSLESS 0x0163
@@ -124,6 +141,7 @@ typedef struct _WAVEFORMATEX {
#define WAVE_FORMAT_CREATIVE_ADPCM 0x0200 /* Creative Labs, Inc */
#define WAVE_FORMAT_CREATIVE_FASTSPEECH8 0x0202 /* Creative Labs, Inc */
#define WAVE_FORMAT_CREATIVE_FASTSPEECH10 0x0203 /* Creative Labs, Inc */
+#define WAVE_FORMAT_GENERIC_PASSTHRU 0x0249
#define WAVE_FORMAT_FM_TOWNS_SND 0x0300 /* Fujitsu Corp. */
#define WAVE_FORMAT_OLIGSM 0x1000 /* Ing C. Olivetti & C., S.p.A. */
#define WAVE_FORMAT_OLIADPCM 0x1001 /* Ing C. Olivetti & C., S.p.A. */
@@ -131,14 +149,19 @@ typedef struct _WAVEFORMATEX {
#define WAVE_FORMAT_OLISBC 0x1003 /* Ing C. Olivetti & C., S.p.A. */
#define WAVE_FORMAT_OLIOPR 0x1004 /* Ing C. Olivetti & C., S.p.A. */
#define WAVE_FORMAT_MPEG_ADTS_AAC 0x1600
+#define WAVE_FORMAT_MPEG_RAW_AAC 0x1601
+#define WAVE_FORMAT_MPEG_LOAS 0x1602
#define WAVE_FORMAT_MPEG_HEAAC 0x1610
+#define WAVE_FORMAT_DTS2 0x2001
#define WAVE_FORMAT_ALAC 0x6c61
#define WAVE_FORMAT_OPUS 0x704f
#define WAVE_FORMAT_AMR_NB 0x7361
#define WAVE_FORMAT_AMR_WB 0x7362
#define WAVE_FORMAT_AMR_WP 0x7363
+#define WAVE_FORMAT_MPEG_AAC 0xa106
#define WAVE_FORMAT_FLAC 0xf1ac
+
#ifndef MM_MICROSOFT
#define MM_MICROSOFT 0x01
#endif
@@ -147,6 +170,9 @@ typedef struct _WAVEFORMATEX {
#define MM_MSFT_ACM_GSM610 0x24
#define MM_MSFT_ACM_G711 0x25
#define MM_MSFT_ACM_PCM 0x26
+#define MM_MSFT_ACM_WMAUDIO 39
+#define MM_MSFT_ACM_MSAUDIO1 39
+#define MM_MSFT_ACM_WMAUDIO2 101
#define MM_FRAUNHOFER_IIS 0xAC
#define MM_FHGIIS_MPEGLAYER3_DECODE 0x09
@@ -175,6 +201,15 @@ typedef struct adpcmwaveformat_tag {
typedef ADPCMWAVEFORMAT *PADPCMWAVEFORMAT,
*NPADPCMWAVEFORMAT, *LPADPCMWAVEFORMAT;
+typedef struct drmwaveformat_tag {
+ WAVEFORMATEX wfx;
+ WORD wReserved;
+ ULONG ulContentId;
+ WAVEFORMATEX wfxSecure;
+} DRMWAVEFORMAT;
+typedef DRMWAVEFORMAT *PDRMWAVEFORMAT, *NPDRMWAVEFORMAT,
+ *LPDRMWAVEFORMAT;
+
typedef struct dvi_adpcmwaveformat_tag {
WAVEFORMATEX wfx;
WORD wSamplesPerBlock;
@@ -410,7 +445,9 @@ typedef struct mpeg1waveformat_tag {
WORD fwHeadFlags;
DWORD dwPTSLow;
DWORD dwPTSHigh;
-} MPEG1WAVEFORMAT,* PMPEG1WAVEFORMAT;
+} MPEG1WAVEFORMAT;
+typedef MPEG1WAVEFORMAT *PMPEG1WAVEFORMAT,
+ *NPMPEG1WAVEFORMAT, *LPMPEG1WAVEFORMAT;
#define ACM_MPEG_LAYER1 0x0001
#define ACM_MPEG_LAYER2 0x0002
@@ -434,6 +471,8 @@ typedef struct mpeglayer3waveformat_tag {
WORD nFramesPerBlock;
WORD nCodecDelay;
} MPEGLAYER3WAVEFORMAT;
+typedef MPEGLAYER3WAVEFORMAT *PMPEGLAYER3WAVEFORMAT,
+ *NPMPEGLAYER3WAVEFORMAT, *LPMPEGLAYER3WAVEFORMAT;
#define MPEGLAYER3_WFX_EXTRA_BYTES 12
@@ -445,6 +484,42 @@ typedef struct mpeglayer3waveformat_tag {
#define MPEGLAYER3_FLAG_PADDING_ON 0x00000001
#define MPEGLAYER3_FLAG_PADDING_OFF 0x00000002
+typedef struct msaudio1waveformat_tag {
+ WAVEFORMATEX wfx;
+ WORD wSamplesPerBlock;
+ WORD wEncodeOptions;
+} MSAUDIO1WAVEFORMAT, *LPMSAUDIO1WAVEFORMAT;
+
+#define WMAUDIO_BITS_PER_SAMPLE 16
+#define WMAUDIO_MAX_CHANNELS 2
+
+#define MSAUDIO1_BITS_PER_SAMPLE WMAUDIO_BITS_PER_SAMPLE
+#define MSAUDIO1_MAX_CHANNELS WMAUDIO_MAX_CHANNELS
+#define MSAUDIO1_WFX_EXTRA_BYTES sizeof(MSAUDIO1WAVEFORMAT) - sizeof(WAVEFORMATEX)
+
+typedef struct wmaudio2waveformat_tag {
+ WAVEFORMATEX wfx;
+ DWORD dwSamplesPerBlock;
+ WORD wEncodeOptions;
+ DWORD dwSuperBlockAlign;
+} WMAUDIO2WAVEFORMAT, *LPWMAUDIO2WAVEFORMAT;
+
+#define WMAUDIO2_BITS_PER_SAMPLE WMAUDIO_BITS_PER_SAMPLE
+#define WMAUDIO2_MAX_CHANNELS WMAUDIO_MAX_CHANNELS
+#define WMAUDIO2_WFX_EXTRA_BYTES sizeof(WMAUDIO2WAVEFORMAT) - sizeof(WAVEFORMATEX)
+
+typedef struct wmaudio3waveformat_tag {
+ WAVEFORMATEX wfx;
+ WORD wValidBitsPerSample;
+ DWORD dwChannelMask;
+ DWORD dwReserved1;
+ DWORD dwReserved2;
+ WORD wEncodeOptions;
+ WORD wReserved3;
+} WMAUDIO3WAVEFORMAT, *LPWMAUDIO3WAVEFORMAT;
+
+#define WMAUDIO3_WFX_EXTRA_BYTES sizeof(WMAUDIO3WAVEFORMAT) - sizeof(WAVEFORMATEX)
+
#ifdef GUID_DEFINED
#ifndef _WAVEFORMATEXTENSIBLE_
@@ -499,7 +574,6 @@ typedef WAVEFORMATIEEEFLOATEX* LPWAVEFORMATIEEEFLOATEX;
#endif /* _SPEAKER_POSITIONS_ */
-
/* DIB stuff */
#ifndef BI_BITFIELDS
diff --git a/include/mmsystem.h b/include/mmsystem.h
index ee7e316660..2a0782d0cb 100644
--- a/include/mmsystem.h
+++ b/include/mmsystem.h
@@ -474,6 +474,7 @@ DECL_WINELIB_TYPE_AW(LPWAVEINCAPS2)
#define WAVE_FORMAT_96M16 0x00040000 /* 96 kHz, Mono, 16-bit */
#define WAVE_FORMAT_96S16 0x00080000 /* 96 kHz, Stereo, 16-bit */
+#ifndef WAVE_FORMAT_PCM
/* General format structure common to all formats, same for Win16 and Win32 */
typedef struct waveformat_tag {
WORD wFormatTag;
@@ -483,14 +484,13 @@ typedef struct waveformat_tag {
WORD nBlockAlign;
} WAVEFORMAT, *LPWAVEFORMAT;
-#ifndef WAVE_FORMAT_PCM
#define WAVE_FORMAT_PCM 1
-#endif
typedef struct pcmwaveformat_tag {
WAVEFORMAT wf;
WORD wBitsPerSample;
} PCMWAVEFORMAT, *LPPCMWAVEFORMAT;
+#endif
#ifndef _WAVEFORMATEX_
#define _WAVEFORMATEX_
--
2.21.0
March 31, 2019
Re: [PATCH] include: add missing tags and defines in mmreg.h
by Marvin
Hi,
While running your changed tests, I think I found new failures.
Being a bot and all I'm not very good at pattern recognition, so I might be
wrong, but could you please double-check?
Full results can be found at:
https://testbot.winehq.org/JobDetails.pl?Key=50212
Your paranoid android.
=== debian9 (build log) ===
../../../../wine/include/mmsystem.h:478:16: error: redefinition of ‘struct waveformat_tag’
../../../../wine/include/mmsystem.h:484:3: error: conflicting types for ‘WAVEFORMAT’
../../../../wine/include/mmsystem.h:484:16: error: conflicting types for ‘LPWAVEFORMAT’
../../../../wine/include/mmsystem.h:490:16: error: redefinition of ‘struct pcmwaveformat_tag’
../../../../wine/include/mmsystem.h:493:3: error: conflicting types for ‘PCMWAVEFORMAT’
../../../../wine/include/mmsystem.h:493:19: error: conflicting types for ‘LPPCMWAVEFORMAT’
Makefile:167: recipe for target 'mp3dmod.o' failed
Makefile:8681: recipe for target 'dlls/mp3dmod/tests' failed
../../../../wine/include/mmsystem.h:478:16: error: redefinition of ‘struct waveformat_tag’
../../../../wine/include/mmsystem.h:484:3: error: conflicting types for ‘WAVEFORMAT’
../../../../wine/include/mmsystem.h:484:16: error: conflicting types for ‘LPWAVEFORMAT’
../../../../wine/include/mmsystem.h:490:16: error: redefinition of ‘struct pcmwaveformat_tag’
../../../../wine/include/mmsystem.h:493:3: error: conflicting types for ‘PCMWAVEFORMAT’
../../../../wine/include/mmsystem.h:493:19: error: conflicting types for ‘LPPCMWAVEFORMAT’
Makefile:270: recipe for target 'mmdevenum.o' failed
Makefile:8681: recipe for target 'dlls/mmdevapi/tests' failed
Task: The win32 build failed
=== debian9 (build log) ===
../../../../wine/include/mmsystem.h:478:16: error: redefinition of ‘struct waveformat_tag’
../../../../wine/include/mmsystem.h:484:3: error: conflicting types for ‘WAVEFORMAT’
../../../../wine/include/mmsystem.h:484:16: error: conflicting types for ‘LPWAVEFORMAT’
../../../../wine/include/mmsystem.h:490:16: error: redefinition of ‘struct pcmwaveformat_tag’
../../../../wine/include/mmsystem.h:493:3: error: conflicting types for ‘PCMWAVEFORMAT’
../../../../wine/include/mmsystem.h:493:19: error: conflicting types for ‘LPPCMWAVEFORMAT’
Makefile:270: recipe for target 'mmdevenum.o' failed
../../../../wine/include/mmsystem.h:478:16: error: redefinition of ‘struct waveformat_tag’
../../../../wine/include/mmsystem.h:484:3: error: conflicting types for ‘WAVEFORMAT’
../../../../wine/include/mmsystem.h:484:16: error: conflicting types for ‘LPWAVEFORMAT’
../../../../wine/include/mmsystem.h:490:16: error: redefinition of ‘struct pcmwaveformat_tag’
../../../../wine/include/mmsystem.h:493:3: error: conflicting types for ‘PCMWAVEFORMAT’
../../../../wine/include/mmsystem.h:493:19: error: conflicting types for ‘LPPCMWAVEFORMAT’
Makefile:167: recipe for target 'mp3dmod.o' failed
Makefile:8408: recipe for target 'dlls/mp3dmod/tests' failed
Makefile:8408: recipe for target 'dlls/mmdevapi/tests' failed
Task: The wow64 build failed
March 31, 2019
[PATCH] include: add missing tags and defines in mmreg.h
by Vijay Kiran Kamuju
From: Vijay Kiran Kamuju <infyquest(a)gmail.com>
Signed-off-by: Vijay Kiran Kamuju <infyquest(a)gmail.com>
---
include/mmreg.h | 78 +++++++++++++++++++++++++++++++++++++++++++++++--
1 file changed, 76 insertions(+), 2 deletions(-)
diff --git a/include/mmreg.h b/include/mmreg.h
index e7d70bbd63..edb209907d 100644
--- a/include/mmreg.h
+++ b/include/mmreg.h
@@ -75,6 +75,21 @@ typedef struct _WAVEFORMATEX {
} WAVEFORMATEX, *PWAVEFORMATEX, *NPWAVEFORMATEX, *LPWAVEFORMATEX;
#endif /* _WAVEFORMATEX_ */
+#ifndef WAVE_FORMAT_PCM
+typedef struct waveformat_tag {
+ WORD wFormatTag;
+ WORD nChannels;
+ DWORD nSamplesPerSec;
+ DWORD nAvgBytesPerSec;
+ WORD nBlockAlign;
+} WAVEFORMAT, *PWAVEFORMAT, *NPWAVEFORMAT, *LPWAVEFORMAT;
+
+typedef struct pcmwaveformat_tag {
+ WAVEFORMAT wf;
+ WORD wBitsPerSample;
+} PCMWAVEFORMAT, *PPCMWAVEFORMAT, *NPPCMWAVEFORMAT, *LPPCMWAVEFORMAT;
+#endif /* WAVE_FORMAT_PCM */
+
/* WAVE form wFormatTag IDs */
#define WAVE_FORMAT_UNKNOWN 0x0000 /* Microsoft Corporation */
#ifndef WAVE_FORMAT_PCM
@@ -117,6 +132,8 @@ typedef struct _WAVEFORMATEX {
#define WAVE_FORMAT_MPEGLAYER3 0x0055
#define WAVE_FORMAT_MSRT24 0x0082 /* Microsoft Corporation */
#define WAVE_FORMAT_DOLBY_AC3_SPDIF 0x0092
+#define WAVE_FORMAT_RAW_AAC1 0x00FF
+#define WAVE_FORMAT_MSAUDIO1 0x0160
#define WAVE_FORMAT_WMAUDIO2 0x0161
#define WAVE_FORMAT_WMAUDIO3 0x0162
#define WAVE_FORMAT_WMAUDIO_LOSSLESS 0x0163
@@ -124,6 +141,7 @@ typedef struct _WAVEFORMATEX {
#define WAVE_FORMAT_CREATIVE_ADPCM 0x0200 /* Creative Labs, Inc */
#define WAVE_FORMAT_CREATIVE_FASTSPEECH8 0x0202 /* Creative Labs, Inc */
#define WAVE_FORMAT_CREATIVE_FASTSPEECH10 0x0203 /* Creative Labs, Inc */
+#define WAVE_FORMAT_GENERIC_PASSTHRU 0x0249
#define WAVE_FORMAT_FM_TOWNS_SND 0x0300 /* Fujitsu Corp. */
#define WAVE_FORMAT_OLIGSM 0x1000 /* Ing C. Olivetti & C., S.p.A. */
#define WAVE_FORMAT_OLIADPCM 0x1001 /* Ing C. Olivetti & C., S.p.A. */
@@ -131,14 +149,19 @@ typedef struct _WAVEFORMATEX {
#define WAVE_FORMAT_OLISBC 0x1003 /* Ing C. Olivetti & C., S.p.A. */
#define WAVE_FORMAT_OLIOPR 0x1004 /* Ing C. Olivetti & C., S.p.A. */
#define WAVE_FORMAT_MPEG_ADTS_AAC 0x1600
+#define WAVE_FORMAT_MPEG_RAW_AAC 0x1601
+#define WAVE_FORMAT_MPEG_LOAS 0x1602
#define WAVE_FORMAT_MPEG_HEAAC 0x1610
+#define WAVE_FORMAT_DTS2 0x2001
#define WAVE_FORMAT_ALAC 0x6c61
#define WAVE_FORMAT_OPUS 0x704f
#define WAVE_FORMAT_AMR_NB 0x7361
#define WAVE_FORMAT_AMR_WB 0x7362
#define WAVE_FORMAT_AMR_WP 0x7363
+#define WAVE_FORMAT_MPEG_AAC 0xa106
#define WAVE_FORMAT_FLAC 0xf1ac
+
#ifndef MM_MICROSOFT
#define MM_MICROSOFT 0x01
#endif
@@ -147,6 +170,9 @@ typedef struct _WAVEFORMATEX {
#define MM_MSFT_ACM_GSM610 0x24
#define MM_MSFT_ACM_G711 0x25
#define MM_MSFT_ACM_PCM 0x26
+#define MM_MSFT_ACM_WMAUDIO 39
+#define MM_MSFT_ACM_MSAUDIO1 39
+#define MM_MSFT_ACM_WMAUDIO2 101
#define MM_FRAUNHOFER_IIS 0xAC
#define MM_FHGIIS_MPEGLAYER3_DECODE 0x09
@@ -175,6 +201,15 @@ typedef struct adpcmwaveformat_tag {
typedef ADPCMWAVEFORMAT *PADPCMWAVEFORMAT,
*NPADPCMWAVEFORMAT, *LPADPCMWAVEFORMAT;
+typedef struct drmwaveformat_tag {
+ WAVEFORMATEX wfx;
+ WORD wReserved;
+ ULONG ulContentId;
+ WAVEFORMATEX wfxSecure;
+} DRMWAVEFORMAT;
+typedef DRMWAVEFORMAT *PDRMWAVEFORMAT, *NPDRMWAVEFORMAT,
+ *LPDRMWAVEFORMAT;
+
typedef struct dvi_adpcmwaveformat_tag {
WAVEFORMATEX wfx;
WORD wSamplesPerBlock;
@@ -410,7 +445,9 @@ typedef struct mpeg1waveformat_tag {
WORD fwHeadFlags;
DWORD dwPTSLow;
DWORD dwPTSHigh;
-} MPEG1WAVEFORMAT,* PMPEG1WAVEFORMAT;
+} MPEG1WAVEFORMAT;
+typedef MPEG1WAVEFORMAT *PMPEG1WAVEFORMAT,
+ *NPMPEG1WAVEFORMAT, *LPMPEG1WAVEFORMAT;
#define ACM_MPEG_LAYER1 0x0001
#define ACM_MPEG_LAYER2 0x0002
@@ -434,6 +471,8 @@ typedef struct mpeglayer3waveformat_tag {
WORD nFramesPerBlock;
WORD nCodecDelay;
} MPEGLAYER3WAVEFORMAT;
+typedef MPEGLAYER3WAVEFORMAT *PMPEGLAYER3WAVEFORMAT,
+ *NPMPEGLAYER3WAVEFORMAT, *LPMPEGLAYER3WAVEFORMAT;
#define MPEGLAYER3_WFX_EXTRA_BYTES 12
@@ -445,6 +484,42 @@ typedef struct mpeglayer3waveformat_tag {
#define MPEGLAYER3_FLAG_PADDING_ON 0x00000001
#define MPEGLAYER3_FLAG_PADDING_OFF 0x00000002
+typedef struct msaudio1waveformat_tag {
+ WAVEFORMATEX wfx;
+ WORD wSamplesPerBlock;
+ WORD wEncodeOptions;
+} MSAUDIO1WAVEFORMAT, *LPMSAUDIO1WAVEFORMAT;
+
+#define WMAUDIO_BITS_PER_SAMPLE 16
+#define WMAUDIO_MAX_CHANNELS 2
+
+#define MSAUDIO1_BITS_PER_SAMPLE WMAUDIO_BITS_PER_SAMPLE
+#define MSAUDIO1_MAX_CHANNELS WMAUDIO_MAX_CHANNELS
+#define MSAUDIO1_WFX_EXTRA_BYTES sizeof(MSAUDIO1WAVEFORMAT) - sizeof(WAVEFORMATEX)
+
+typedef struct wmaudio2waveformat_tag {
+ WAVEFORMATEX wfx;
+ DWORD dwSamplesPerBlock;
+ WORD wEncodeOptions;
+ DWORD dwSuperBlockAlign;
+} WMAUDIO2WAVEFORMAT, *LPWMAUDIO2WAVEFORMAT;
+
+#define WMAUDIO2_BITS_PER_SAMPLE WMAUDIO_BITS_PER_SAMPLE
+#define WMAUDIO2_MAX_CHANNELS WMAUDIO_MAX_CHANNELS
+#define WMAUDIO2_WFX_EXTRA_BYTES sizeof(WMAUDIO2WAVEFORMAT) - sizeof(WAVEFORMATEX)
+
+typedef struct wmaudio3waveformat_tag {
+ WAVEFORMATEX wfx;
+ WORD wValidBitsPerSample;
+ DWORD dwChannelMask;
+ DWORD dwReserved1;
+ DWORD dwReserved2;
+ WORD wEncodeOptions;
+ WORD wReserved3;
+} WMAUDIO3WAVEFORMAT, *LPWMAUDIO3WAVEFORMAT;
+
+#define WMAUDIO3_WFX_EXTRA_BYTES sizeof(WMAUDIO3WAVEFORMAT) - sizeof(WAVEFORMATEX)
+
#ifdef GUID_DEFINED
#ifndef _WAVEFORMATEXTENSIBLE_
@@ -499,7 +574,6 @@ typedef WAVEFORMATIEEEFLOATEX* LPWAVEFORMATIEEEFLOATEX;
#endif /* _SPEAKER_POSITIONS_ */
-
/* DIB stuff */
#ifndef BI_BITFIELDS
--
2.21.0
March 31, 2019
Re: [PATCH v2 2/2] kernel32: Stub FindFirstStreamW/FindNextStreamW
by Marvin
Hi,
While running your changed tests, I think I found new failures.
Being a bot and all I'm not very good at pattern recognition, so I might be
wrong, but could you please double-check?
Full results can be found at:
https://testbot.winehq.org/JobDetails.pl?Key=50210
Your paranoid android.
=== wxppro (32 bit report) ===
kernel32:
file: Timeout
=== debian9 (64 bit WoW report) ===
kernel32:
change.c:320: Test failed: should be ready
March 31, 2019
[PATCH] ntdll: Add stub for RtlInstallFunctionTableCallback on ARM/ARM64
by André Hentschel
Signed-off-by: André Hentschel <nerv(a)dawncrow.de>
---
dlls/ntdll/ntdll.spec | 2 +-
dlls/ntdll/signal_arm.c | 10 ++++++++++
dlls/ntdll/signal_arm64.c | 10 ++++++++++
include/winnt.h | 6 ++++++
4 files changed, 27 insertions(+), 1 deletion(-)
diff --git a/dlls/ntdll/ntdll.spec b/dlls/ntdll/ntdll.spec
index 0ff695aa9ca..233c4ef8797 100644
--- a/dlls/ntdll/ntdll.spec
+++ b/dlls/ntdll/ntdll.spec
@@ -722,7 +722,7 @@
# @ stub RtlInitializeStackTraceDataBase
@ stub RtlInsertElementGenericTable
@ stdcall RtlInsertElementGenericTableAvl(ptr ptr long ptr)
-@ cdecl -arch=x86_64 RtlInstallFunctionTableCallback(long long long ptr ptr wstr)
+@ cdecl -arch=arm,arm64,x86_64 RtlInstallFunctionTableCallback(long long long ptr ptr wstr)
@ stdcall RtlInt64ToUnicodeString(int64 long ptr)
@ stdcall RtlIntegerToChar(long long long ptr)
@ stdcall RtlIntegerToUnicodeString(long long ptr)
diff --git a/dlls/ntdll/signal_arm.c b/dlls/ntdll/signal_arm.c
index 75a1133b4fd..32205ea39c3 100644
--- a/dlls/ntdll/signal_arm.c
+++ b/dlls/ntdll/signal_arm.c
@@ -1058,6 +1058,16 @@ BOOLEAN CDECL RtlAddFunctionTable( RUNTIME_FUNCTION *table, DWORD count, DWORD a
return TRUE;
}
+/**********************************************************************
+ * RtlInstallFunctionTableCallback (NTDLL.@)
+ */
+BOOLEAN CDECL RtlInstallFunctionTableCallback( DWORD table, DWORD base, DWORD length,
+ PGET_RUNTIME_FUNCTION_CALLBACK callback, PVOID context, PCWSTR dll )
+{
+ FIXME( "%x %x %d %p %p %s: stub\n", table, base, length, callback, context, wine_dbgstr_w(dll) );
+ return TRUE;
+}
+
/*************************************************************************
* RtlAddGrowableFunctionTable (NTDLL.@)
*/
diff --git a/dlls/ntdll/signal_arm64.c b/dlls/ntdll/signal_arm64.c
index 1d26125209e..423da258705 100644
--- a/dlls/ntdll/signal_arm64.c
+++ b/dlls/ntdll/signal_arm64.c
@@ -977,6 +977,16 @@ BOOLEAN CDECL RtlAddFunctionTable( RUNTIME_FUNCTION *table, DWORD count, ULONG_P
return TRUE;
}
+/**********************************************************************
+ * RtlInstallFunctionTableCallback (NTDLL.@)
+ */
+BOOLEAN CDECL RtlInstallFunctionTableCallback( ULONG_PTR table, ULONG_PTR base, DWORD length,
+ PGET_RUNTIME_FUNCTION_CALLBACK callback, PVOID context, PCWSTR dll )
+{
+ FIXME( "%lx %lx %d %p %p %s: stub\n", table, base, length, callback, context, wine_dbgstr_w(dll) );
+ return TRUE;
+}
+
/*************************************************************************
* RtlAddGrowableFunctionTable (NTDLL.@)
diff --git a/include/winnt.h b/include/winnt.h
index 5694ad7c01f..28e87c7dff3 100644
--- a/include/winnt.h
+++ b/include/winnt.h
@@ -1745,8 +1745,11 @@ typedef struct _CONTEXT
ULONG Padding2[2]; /* 198 */
} CONTEXT;
+typedef PRUNTIME_FUNCTION (CALLBACK *PGET_RUNTIME_FUNCTION_CALLBACK)(DWORD,PVOID);
+
BOOLEAN CDECL RtlAddFunctionTable(RUNTIME_FUNCTION*,DWORD,DWORD);
BOOLEAN CDECL RtlDeleteFunctionTable(RUNTIME_FUNCTION*);
+BOOLEAN CDECL RtlInstallFunctionTableCallback(DWORD,DWORD,DWORD,PGET_RUNTIME_FUNCTION_CALLBACK,PVOID,PCWSTR);
PRUNTIME_FUNCTION WINAPI RtlLookupFunctionEntry(ULONG_PTR,DWORD*,UNWIND_HISTORY_TABLE*);
#endif /* __arm__ */
@@ -1878,8 +1881,11 @@ typedef struct _CONTEXT
DWORD64 Wvr[ARM64_MAX_WATCHPOINTS]; /* 380 */
} CONTEXT;
+typedef PRUNTIME_FUNCTION (CALLBACK *PGET_RUNTIME_FUNCTION_CALLBACK)(DWORD64,PVOID);
+
BOOLEAN CDECL RtlAddFunctionTable(RUNTIME_FUNCTION*,DWORD,ULONG_PTR);
BOOLEAN CDECL RtlDeleteFunctionTable(RUNTIME_FUNCTION*);
+BOOLEAN CDECL RtlInstallFunctionTableCallback(ULONG_PTR,ULONG_PTR,DWORD,PGET_RUNTIME_FUNCTION_CALLBACK,PVOID,PCWSTR);
#endif /* __aarch64__ */
--
2.17.1
March 31, 2019
[PATCH v2 2/2] kernel32: Stub FindFirstStreamW/FindNextStreamW
by Fabian Maurer
Follow up to https://bugs.winehq.org/show_bug.cgi?id=46927
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=46934
Signed-off-by: Fabian Maurer <dark.shadow4(a)web.de>
---
dlls/kernel32/file.c | 25 +++++++++++++++++++++++++
dlls/kernel32/kernel32.spec | 4 ++--
dlls/kernel32/tests/file.c | 15 +++++++++++++++
include/winbase.h | 13 +++++++++++++
4 files changed, 55 insertions(+), 2 deletions(-)
diff --git a/dlls/kernel32/file.c b/dlls/kernel32/file.c
index 3214d724cb..aa3eb34d38 100644
--- a/dlls/kernel32/file.c
+++ b/dlls/kernel32/file.c
@@ -2349,6 +2349,31 @@ BOOL WINAPI FindNextFileA( HANDLE handle, WIN32_FIND_DATAA *data )
}
+/**************************************************************************
+ * FindFirstStreamW (KERNEL32.@)
+ */
+HANDLE WINAPI FindFirstStreamW(LPCWSTR filename, STREAM_INFO_LEVELS infolevel,
+ void *data, DWORD flags)
+{
+ FIXME("(%s, %d, %p, %x): stub!\n", debugstr_w(filename), infolevel, data, flags);
+
+ SetLastError(ERROR_HANDLE_EOF);
+ return INVALID_HANDLE_VALUE;
+}
+
+
+/**************************************************************************
+ * FindNextStreamW (KERNEL32.@)
+ */
+BOOL WINAPI FindNextStreamW(HANDLE handle, void *data)
+{
+ FIXME("(%p, %p): stub!\n", handle, data);
+
+ SetLastError(ERROR_HANDLE_EOF);
+ return FALSE;
+}
+
+
/**************************************************************************
* GetFileAttributesW (KERNEL32.@)
*/
diff --git a/dlls/kernel32/kernel32.spec b/dlls/kernel32/kernel32.spec
index 1cf7b58a02..776d83bc84 100644
--- a/dlls/kernel32/kernel32.spec
+++ b/dlls/kernel32/kernel32.spec
@@ -488,7 +488,7 @@
# @ stub FindFirstFileTransactedW
@ stdcall FindFirstFileW(wstr ptr)
# @ stub FindFirstStreamTransactedW
-# @ stub FindFirstStreamW
+@ stdcall FindFirstStreamW(wstr long ptr long)
@ stdcall FindFirstVolumeA(ptr long)
@ stdcall FindFirstVolumeMountPointA(str ptr long)
@ stdcall FindFirstVolumeMountPointW(wstr ptr long)
@@ -497,7 +497,7 @@
@ stdcall FindNextFileA(long ptr)
# @ stub FindNextFileNameW
@ stdcall FindNextFileW(long ptr)
-# @ stub FindNextStreamW
+@ stdcall FindNextStreamW(long ptr)
@ stdcall FindNextVolumeA(long ptr long)
@ stub FindNextVolumeMountPointA
@ stub FindNextVolumeMountPointW
diff --git a/dlls/kernel32/tests/file.c b/dlls/kernel32/tests/file.c
index 33b17aa327..adf849590e 100644
--- a/dlls/kernel32/tests/file.c
+++ b/dlls/kernel32/tests/file.c
@@ -5228,6 +5228,20 @@ static void test_overlapped_read(void)
ok(ret, "Unexpected error %u.\n", GetLastError());
}
+static void test_find_file_stream(void)
+{
+ WCHAR path[] = {'C',':','\\','w','i','n','d','o','w','s',0};
+ HANDLE handle;
+ int error;
+ WIN32_FIND_STREAM_DATA data;
+
+ SetLastError(0xdeadbeef);
+ handle = FindFirstStreamW(path, FindStreamInfoStandard, &data, 0);
+ error = GetLastError();
+ ok(handle == INVALID_HANDLE_VALUE, "Expected INVALID_HANDLE_VALUE, got %x\n", handle);
+ ok(error == ERROR_HANDLE_EOF, "Expected ERROR_HANDLE_EOF, got %d\n", error);
+}
+
START_TEST(file)
{
char temp_path[MAX_PATH];
@@ -5298,4 +5312,5 @@ START_TEST(file)
test_GetFileAttributesExW();
test_post_completion();
test_overlapped_read();
+ test_find_file_stream();
}
diff --git a/include/winbase.h b/include/winbase.h
index 49d0e7ed08..c2e216cb91 100644
--- a/include/winbase.h
+++ b/include/winbase.h
@@ -1717,6 +1717,17 @@ typedef struct _UMS_SCHEDULER_STARTUP_INFO
typedef enum _RTL_UMS_SCHEDULER_REASON UMS_SCHEDULER_REASON;
typedef enum _RTL_UMS_THREAD_INFO_CLASS UMS_THREAD_INFO_CLASS, *PUMS_THREAD_INFO_CLASS;
+typedef enum _STREAM_INFO_LEVELS
+{
+ FindStreamInfoStandard,
+ FindStreamInfoMaxInfoLevel
+} STREAM_INFO_LEVELS;
+
+typedef struct _WIN32_FIND_STREAM_DATA {
+ LARGE_INTEGER StreamSize;
+ WCHAR cStreamName[MAX_PATH + 36];
+} WIN32_FIND_STREAM_DATA,*PWIN32_FIND_STREAM_DATA;
+
WINBASEAPI BOOL WINAPI ActivateActCtx(HANDLE,ULONG_PTR *);
WINADVAPI BOOL WINAPI AddAccessAllowedAce(PACL,DWORD,DWORD,PSID);
WINADVAPI BOOL WINAPI AddAccessAllowedAceEx(PACL,DWORD,DWORD,DWORD,PSID);
@@ -2002,10 +2013,12 @@ WINBASEAPI HANDLE WINAPI FindFirstFileExA(LPCSTR,FINDEX_INFO_LEVELS,LPVOID,
WINBASEAPI HANDLE WINAPI FindFirstFileExW(LPCWSTR,FINDEX_INFO_LEVELS,LPVOID,FINDEX_SEARCH_OPS,LPVOID,DWORD);
#define FindFirstFileEx WINELIB_NAME_AW(FindFirstFileEx)
WINADVAPI BOOL WINAPI FindFirstFreeAce(PACL,LPVOID*);
+WINBASEAPI HANDLE WINAPI FindFirstStreamW(LPCWSTR,STREAM_INFO_LEVELS,void*,DWORD);
WINBASEAPI BOOL WINAPI FindNextChangeNotification(HANDLE);
WINBASEAPI BOOL WINAPI FindNextFileA(HANDLE,LPWIN32_FIND_DATAA);
WINBASEAPI BOOL WINAPI FindNextFileW(HANDLE,LPWIN32_FIND_DATAW);
#define FindNextFile WINELIB_NAME_AW(FindNextFile)
+WINBASEAPI BOOL WINAPI FindNextStreamW(HANDLE,void*);
WINBASEAPI BOOL WINAPI FindCloseChangeNotification(HANDLE);
WINBASEAPI HRSRC WINAPI FindResourceA(HMODULE,LPCSTR,LPCSTR);
WINBASEAPI HRSRC WINAPI FindResourceW(HMODULE,LPCWSTR,LPCWSTR);
--
2.21.0
March 31, 2019
[PATCH v2 1/2] kernel32: Partially implement VirtualAllocExNuma
by Fabian Maurer
Ignoring the preferred node should be good enough
Wine-Bug: https://bugs.winehq.org/show_bug.cgi?id=46927
Signed-off-by: Fabian Maurer <dark.shadow4(a)web.de>
---
dlls/kernel32/kernel32.spec | 2 +-
dlls/kernel32/virtual.c | 27 +++++++++++++++++++++++++++
include/winbase.h | 1 +
3 files changed, 29 insertions(+), 1 deletion(-)
diff --git a/dlls/kernel32/kernel32.spec b/dlls/kernel32/kernel32.spec
index c8d52cec58..1cf7b58a02 100644
--- a/dlls/kernel32/kernel32.spec
+++ b/dlls/kernel32/kernel32.spec
@@ -1559,7 +1559,7 @@
@ stdcall VerifyVersionInfoW(long long int64)
@ stdcall VirtualAlloc(ptr long long long)
@ stdcall VirtualAllocEx(long ptr long long long)
-# @ stub VirtualAllocExNuma
+@ stdcall VirtualAllocExNuma(long ptr long long long long)
@ stub VirtualBufferExceptionHandler
@ stdcall VirtualFree(ptr long long)
@ stdcall VirtualFreeEx(long ptr long long)
diff --git a/dlls/kernel32/virtual.c b/dlls/kernel32/virtual.c
index 42da7f0d8c..35ca4c0876 100644
--- a/dlls/kernel32/virtual.c
+++ b/dlls/kernel32/virtual.c
@@ -46,6 +46,7 @@
WINE_DECLARE_DEBUG_CHANNEL(seh);
WINE_DECLARE_DEBUG_CHANNEL(file);
+WINE_DECLARE_DEBUG_CHANNEL(virtual);
/***********************************************************************
@@ -100,6 +101,32 @@ LPVOID WINAPI DECLSPEC_HOTPATCH VirtualAllocEx( HANDLE hProcess, LPVOID addr, SI
return ret;
}
+/***********************************************************************
+ * VirtualAllocExNuma (KERNEL32.@)
+ *
+ * Seems to be just as VirtualAllocEx, but with a preferred NUMA node.
+ *
+ * PARAMS
+ * process [I] Handle to process to do mem operation.
+ * addr [I] Address of region to reserve or commit.
+ * size [I] Size of region.
+ * type [I] Type of allocation.
+ * protect [I] Type of access protection.
+ * numa_node[I] Preferred NUMA node.
+ *
+ *
+ * RETURNS
+ * Success: Base address of allocated region of pages.
+ * Failure: NULL.
+ */
+LPVOID WINAPI DECLSPEC_HOTPATCH VirtualAllocExNuma(HANDLE process, void *addr, SIZE_T size,
+ DWORD type, DWORD protect, DWORD numa_node)
+{
+ FIXME_(virtual)("Ignoring preferred numa_node\n");
+
+ return VirtualAllocEx(process, addr, size, type, protect);
+}
+
/***********************************************************************
* VirtualFree (KERNEL32.@)
diff --git a/include/winbase.h b/include/winbase.h
index 20c73af319..49d0e7ed08 100644
--- a/include/winbase.h
+++ b/include/winbase.h
@@ -2698,6 +2698,7 @@ WINBASEAPI BOOL WINAPI VerifyVersionInfoW(LPOSVERSIONINFOEXW,DWORD,DWORDL
#define VerifyVersionInfo WINELIB_NAME_AW(VerifyVersionInfo)
WINBASEAPI LPVOID WINAPI VirtualAlloc(LPVOID,SIZE_T,DWORD,DWORD);
WINBASEAPI LPVOID WINAPI VirtualAllocEx(HANDLE,LPVOID,SIZE_T,DWORD,DWORD);
+WINBASEAPI LPVOID WINAPI VirtualAllocExNuma(HANDLE,void*,SIZE_T,DWORD,DWORD,DWORD);
WINBASEAPI BOOL WINAPI VirtualFree(LPVOID,SIZE_T,DWORD);
WINBASEAPI BOOL WINAPI VirtualFreeEx(HANDLE,LPVOID,SIZE_T,DWORD);
WINBASEAPI BOOL WINAPI VirtualLock(LPVOID,SIZE_T);
--
2.21.0
March 31, 2019
[PATCH] tools: Increase the failure limit to get more win10 test runs displayed on the winetest result pages
by Detlef Riekenberg
The old puffer was not big enough.
winetest results for win10 v1803 should now reach the result page
Mar 31 00:25:01 cw1-hd6800-1803-t64: too many failed test units (>70 at user32:win)
Mar 30 23:50:02 cw1-hd6800-1803-t32: too many failed test units (>70 at wininet:internet)
Mar 30 15:35:02 cw2-gtx560-1803-t64: too many failed test units (>70 at vbscript:createobj)
Mar 30 15:05:02 cw2-gtx560-1803-t32: too many failed test units (>70 at wininet:internet)
(My win10 test machine had 90 failures on 12.March and reached the old limit at urlmon:url)
There will be still test machines rejected:
*cw2-gtx560-wow64 reaches 50 failures at dinput:mouse
this is too far away from a usable limit
*winetest reports other machines reach the file size limit
(newtb-debian9-wow64, fg-deb64-wow32, fg-deb64-wow64,fg-deb64-t32, fgtb-debian9-wow64)
Some of them reach the current filesize limit near the end (urlmon or user32).
Relaxing the limit by 500k might be enough, to get these test results displayed,
bur that is only useful, when someone works on fixing the failures.
--
bye bye ...
... Detlef
---
winetest/dissect | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/winetest/dissect b/winetest/dissect
index a468812..86a5dc2 100755
--- a/winetest/dissect
+++ b/winetest/dissect
@@ -369,7 +369,7 @@ foreach my $entry (@idmatch)
}
}
# Give a little slack to the Windows 10 1709.
-$maxfailedtests += 20 if ($version eq "win10");
+$maxfailedtests += 45 if ($version eq "win10");
if ($prediluvian and not $acceptprediluvianwin)
{
--
2.21.0.windows.1
March 31, 2019