Wine-Devel
Threads by month
- ----- 2026 -----
- 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
- 7 participants
- 84546 discussions
[PATCH vkd3d 2/3] vkd3d-shader: Fix some DWORD/unsigned int pointer mismatches.
by Alexandre Julliard Jan. 31, 2022
by Alexandre Julliard Jan. 31, 2022
Jan. 31, 2022
Signed-off-by: Alexandre Julliard <julliard(a)winehq.org>
---
libs/vkd3d-shader/hlsl.y | 10 +++++-----
1 file changed, 5 insertions(+), 5 deletions(-)
diff --git a/libs/vkd3d-shader/hlsl.y b/libs/vkd3d-shader/hlsl.y
index 9476765fb7af..be24a74963dd 100644
--- a/libs/vkd3d-shader/hlsl.y
+++ b/libs/vkd3d-shader/hlsl.y
@@ -1155,7 +1155,7 @@ static struct hlsl_ir_node *add_assignment(struct hlsl_ctx *ctx, struct list *in
struct hlsl_type *lhs_type = lhs->data_type;
struct hlsl_ir_store *store;
struct hlsl_ir_expr *copy;
- DWORD writemask = 0;
+ unsigned int writemask = 0;
if (assign_op == ASSIGN_OP_SUB)
{
@@ -2359,7 +2359,7 @@ struct_declaration:
var_modifiers struct_spec variables_def_optional ';'
{
struct hlsl_type *type;
- DWORD modifiers = $1;
+ unsigned int modifiers = $1;
if (!$3)
{
@@ -2449,7 +2449,7 @@ field:
var_modifiers field_type variables_def ';'
{
struct hlsl_type *type;
- DWORD modifiers = $1;
+ unsigned int modifiers = $1;
if (!(type = apply_type_modifiers(ctx, $2, &modifiers, @1)))
YYABORT;
@@ -2619,7 +2619,7 @@ parameter:
input_mods var_modifiers type any_identifier colon_attribute
{
struct hlsl_type *type;
- DWORD modifiers = $2;
+ unsigned int modifiers = $2;
if (!(type = apply_type_modifiers(ctx, $3, &modifiers, @2)))
YYABORT;
@@ -2858,7 +2858,7 @@ declaration:
var_modifiers type variables_def ';'
{
struct hlsl_type *type;
- DWORD modifiers = $1;
+ unsigned int modifiers = $1;
if (!(type = apply_type_modifiers(ctx, $2, &modifiers, @1)))
YYABORT;
--
2.34.1
2
1
[PATCH vkd3d 1/3] vkd3d-shader: Consistently use uint32_t for pointers to shader data.
by Alexandre Julliard Jan. 31, 2022
by Alexandre Julliard Jan. 31, 2022
Jan. 31, 2022
Mixing uint32_t and DWORD pointers causes warnings on Windows.
Signed-off-by: Alexandre Julliard <julliard(a)winehq.org>
---
libs/vkd3d-shader/dxbc.c | 50 ++++++++++++------------
libs/vkd3d-shader/vkd3d_shader_private.h | 4 +-
2 files changed, 27 insertions(+), 27 deletions(-)
diff --git a/libs/vkd3d-shader/dxbc.c b/libs/vkd3d-shader/dxbc.c
index 4d3773190875..d28c303ab7ac 100644
--- a/libs/vkd3d-shader/dxbc.c
+++ b/libs/vkd3d-shader/dxbc.c
@@ -87,7 +87,7 @@ struct vkd3d_shader_src_param_entry
struct vkd3d_shader_sm4_parser
{
- const DWORD *start, *end;
+ const uint32_t *start, *end;
unsigned int output_map[MAX_REG_OUTPUT];
@@ -252,7 +252,7 @@ static void shader_sm4_read_dcl_resource(struct vkd3d_shader_instruction *ins, u
{
struct vkd3d_shader_semantic *semantic = &ins->declaration.semantic;
enum vkd3d_sm4_resource_type resource_type;
- const DWORD *end = &tokens[token_count];
+ const uint32_t *end = &tokens[token_count];
enum vkd3d_sm4_data_type data_type;
enum vkd3d_data_type reg_data_type;
DWORD components;
@@ -297,7 +297,7 @@ static void shader_sm4_read_dcl_resource(struct vkd3d_shader_instruction *ins, u
static void shader_sm4_read_dcl_constant_buffer(struct vkd3d_shader_instruction *ins, uint32_t opcode,
uint32_t opcode_token, const uint32_t *tokens, unsigned int token_count, struct vkd3d_shader_sm4_parser *priv)
{
- const DWORD *end = &tokens[token_count];
+ const uint32_t *end = &tokens[token_count];
shader_sm4_read_src_param(priv, &tokens, end, VKD3D_DATA_FLOAT, &ins->declaration.cb.src);
shader_sm4_set_descriptor_register_range(priv, &ins->declaration.cb.src.reg, &ins->declaration.cb.range);
@@ -323,7 +323,7 @@ static void shader_sm4_read_dcl_constant_buffer(struct vkd3d_shader_instruction
static void shader_sm4_read_dcl_sampler(struct vkd3d_shader_instruction *ins, uint32_t opcode, uint32_t opcode_token,
const uint32_t *tokens, unsigned int token_count, struct vkd3d_shader_sm4_parser *priv)
{
- const DWORD *end = &tokens[token_count];
+ const uint32_t *end = &tokens[token_count];
ins->flags = (opcode_token & VKD3D_SM4_SAMPLER_MODE_MASK) >> VKD3D_SM4_SAMPLER_MODE_SHIFT;
if (ins->flags & ~VKD3D_SM4_SAMPLER_COMPARISON)
@@ -342,7 +342,7 @@ static void shader_sm4_read_dcl_index_range(struct vkd3d_shader_instruction *ins
}
static void shader_sm4_read_dcl_output_topology(struct vkd3d_shader_instruction *ins, uint32_t opcode,
- uint32_t opcode_token, const DWORD *tokens, unsigned int token_count, struct vkd3d_shader_sm4_parser *priv)
+ uint32_t opcode_token, const uint32_t *tokens, unsigned int token_count, struct vkd3d_shader_sm4_parser *priv)
{
enum vkd3d_sm4_output_primitive_type primitive_type;
@@ -495,7 +495,7 @@ static void shader_sm5_read_dcl_hs_max_tessfactor(struct vkd3d_shader_instructio
}
static void shader_sm5_read_dcl_thread_group(struct vkd3d_shader_instruction *ins, uint32_t opcode,
- uint32_t opcode_token, const DWORD *tokens, unsigned int token_count, struct vkd3d_shader_sm4_parser *priv)
+ uint32_t opcode_token, const uint32_t *tokens, unsigned int token_count, struct vkd3d_shader_sm4_parser *priv)
{
ins->declaration.thread_group_size.x = *tokens++;
ins->declaration.thread_group_size.y = *tokens++;
@@ -506,7 +506,7 @@ static void shader_sm5_read_dcl_uav_raw(struct vkd3d_shader_instruction *ins, ui
const uint32_t *tokens, unsigned int token_count, struct vkd3d_shader_sm4_parser *priv)
{
struct vkd3d_shader_raw_resource *resource = &ins->declaration.raw_resource;
- const DWORD *end = &tokens[token_count];
+ const uint32_t *end = &tokens[token_count];
shader_sm4_read_dst_param(priv, &tokens, end, VKD3D_DATA_UAV, &resource->resource.reg);
shader_sm4_set_descriptor_register_range(priv, &resource->resource.reg.reg, &resource->resource.range);
@@ -518,7 +518,7 @@ static void shader_sm5_read_dcl_uav_structured(struct vkd3d_shader_instruction *
uint32_t opcode_token, const uint32_t *tokens, unsigned int token_count, struct vkd3d_shader_sm4_parser *priv)
{
struct vkd3d_shader_structured_resource *resource = &ins->declaration.structured_resource;
- const DWORD *end = &tokens[token_count];
+ const uint32_t *end = &tokens[token_count];
shader_sm4_read_dst_param(priv, &tokens, end, VKD3D_DATA_UAV, &resource->resource.reg);
shader_sm4_set_descriptor_register_range(priv, &resource->resource.reg.reg, &resource->resource.range);
@@ -553,7 +553,7 @@ static void shader_sm5_read_dcl_resource_structured(struct vkd3d_shader_instruct
uint32_t opcode_token, const uint32_t *tokens, unsigned int token_count, struct vkd3d_shader_sm4_parser *priv)
{
struct vkd3d_shader_structured_resource *resource = &ins->declaration.structured_resource;
- const DWORD *end = &tokens[token_count];
+ const uint32_t *end = &tokens[token_count];
shader_sm4_read_dst_param(priv, &tokens, end, VKD3D_DATA_RESOURCE, &resource->resource.reg);
shader_sm4_set_descriptor_register_range(priv, &resource->resource.reg.reg, &resource->resource.range);
@@ -567,7 +567,7 @@ static void shader_sm5_read_dcl_resource_raw(struct vkd3d_shader_instruction *in
uint32_t opcode_token, const uint32_t *tokens, unsigned int token_count, struct vkd3d_shader_sm4_parser *priv)
{
struct vkd3d_shader_raw_resource *resource = &ins->declaration.raw_resource;
- const DWORD *end = &tokens[token_count];
+ const uint32_t *end = &tokens[token_count];
shader_sm4_read_dst_param(priv, &tokens, end, VKD3D_DATA_RESOURCE, &resource->resource.reg);
shader_sm4_set_descriptor_register_range(priv, &resource->resource.reg.reg, &resource->resource.range);
@@ -1465,7 +1465,7 @@ static void shader_sm4_read_instruction(struct vkd3d_shader_parser *parser, stru
const uint32_t **ptr = &parser->ptr;
unsigned int i, len;
size_t remaining;
- const DWORD *p;
+ const uint32_t *p;
DWORD precise;
list_move_head(&sm4->src_free, &sm4->src);
@@ -1692,7 +1692,7 @@ static bool require_space(size_t offset, size_t count, size_t size, size_t data_
return !count || (data_size - offset) / count >= size;
}
-static void read_dword(const char **ptr, DWORD *d)
+static void read_dword(const char **ptr, uint32_t *d)
{
memcpy(d, *ptr, sizeof(*d));
*ptr += sizeof(*d);
@@ -1700,14 +1700,14 @@ static void read_dword(const char **ptr, DWORD *d)
static void read_float(const char **ptr, float *f)
{
- STATIC_ASSERT(sizeof(float) == sizeof(DWORD));
- read_dword(ptr, (DWORD *)f);
+ STATIC_ASSERT(sizeof(float) == sizeof(uint32_t));
+ read_dword(ptr, (uint32_t *)f);
}
static void skip_dword_unknown(const char **ptr, unsigned int count)
{
unsigned int i;
- DWORD d;
+ uint32_t d;
WARN("Skipping %u unknown DWORDs:\n", count);
for (i = 0; i < count; ++i)
@@ -1744,11 +1744,11 @@ static int parse_dxbc(const char *data, size_t data_size,
uint32_t checksum[4], calculated_checksum[4];
const char *ptr = data;
int ret = VKD3D_OK;
- DWORD chunk_count;
- DWORD total_size;
+ uint32_t chunk_count;
+ uint32_t total_size;
unsigned int i;
- DWORD version;
- DWORD tag;
+ uint32_t version;
+ uint32_t tag;
if (data_size < VKD3D_DXBC_HEADER_SIZE)
{
@@ -1803,9 +1803,9 @@ static int parse_dxbc(const char *data, size_t data_size,
for (i = 0; i < chunk_count; ++i)
{
- DWORD chunk_tag, chunk_size;
+ uint32_t chunk_tag, chunk_size;
const char *chunk_ptr;
- DWORD chunk_offset;
+ uint32_t chunk_offset;
read_dword(&ptr, &chunk_offset);
TRACE("chunk %u at offset %#x\n", i, chunk_offset);
@@ -1847,7 +1847,7 @@ static int shader_parse_signature(DWORD tag, const char *data, DWORD data_size,
struct vkd3d_shader_signature_element *e;
const char *ptr = data;
unsigned int i;
- DWORD count;
+ uint32_t count;
if (!require_space(0, 2, sizeof(DWORD), data_size))
{
@@ -1877,7 +1877,7 @@ static int shader_parse_signature(DWORD tag, const char *data, DWORD data_size,
for (i = 0; i < count; ++i)
{
- DWORD name_offset, mask;
+ uint32_t name_offset, mask;
if (has_stream_index)
read_dword(&ptr, &e[i].stream_index);
@@ -1998,7 +1998,7 @@ static int shdr_handler(const char *data, DWORD data_size, DWORD tag, void *cont
case TAG_SHEX:
if (desc->byte_code)
FIXME("Multiple shader code chunks.\n");
- desc->byte_code = (const DWORD *)data;
+ desc->byte_code = (const uint32_t *)data;
desc->byte_code_size = data_size;
break;
@@ -2355,7 +2355,7 @@ static int shader_parse_root_parameters(struct root_signature_parser_context *co
}
static int shader_parse_root_parameters1(struct root_signature_parser_context *context,
- DWORD offset, DWORD count, struct vkd3d_shader_root_parameter1 *parameters)
+ uint32_t offset, DWORD count, struct vkd3d_shader_root_parameter1 *parameters)
{
const char *ptr;
unsigned int i;
diff --git a/libs/vkd3d-shader/vkd3d_shader_private.h b/libs/vkd3d-shader/vkd3d_shader_private.h
index 9cd26d7f91a9..1de67f45461a 100644
--- a/libs/vkd3d-shader/vkd3d_shader_private.h
+++ b/libs/vkd3d-shader/vkd3d_shader_private.h
@@ -638,7 +638,7 @@ struct vkd3d_shader_version
struct vkd3d_shader_immediate_constant_buffer
{
unsigned int vec4_count;
- DWORD data[MAX_IMMEDIATE_CONSTANT_BUFFER_SIZE];
+ uint32_t data[MAX_IMMEDIATE_CONSTANT_BUFFER_SIZE];
};
struct vkd3d_shader_indexable_temp
@@ -762,7 +762,7 @@ enum vkd3d_shader_input_sysval_semantic
struct vkd3d_shader_desc
{
- const DWORD *byte_code;
+ const uint32_t *byte_code;
size_t byte_code_size;
struct vkd3d_shader_signature input_signature;
struct vkd3d_shader_signature output_signature;
--
2.34.1
2
1
Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com>
---
dlls/wshom.ocx/Makefile.in | 1 -
dlls/wshom.ocx/shell.c | 97 +++++++++++++++++--------------------
dlls/wshom.ocx/wshom_main.c | 6 +--
3 files changed, 47 insertions(+), 57 deletions(-)
diff --git a/dlls/wshom.ocx/Makefile.in b/dlls/wshom.ocx/Makefile.in
index 70653a1a1f6..fed2babda33 100644
--- a/dlls/wshom.ocx/Makefile.in
+++ b/dlls/wshom.ocx/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = wshom.ocx
IMPORTS = uuid oleaut32 ole32 shell32 user32 advapi32
diff --git a/dlls/wshom.ocx/shell.c b/dlls/wshom.ocx/shell.c
index 1ee74577310..82d618b1142 100644
--- a/dlls/wshom.ocx/shell.c
+++ b/dlls/wshom.ocx/shell.c
@@ -116,7 +116,7 @@ static ULONG WINAPI WshExec_AddRef(IWshExec *iface)
{
WshExecImpl *This = impl_from_IWshExec(iface);
LONG ref = InterlockedIncrement(&This->ref);
- TRACE("(%p) ref = %d\n", This, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
return ref;
}
@@ -124,7 +124,7 @@ static ULONG WINAPI WshExec_Release(IWshExec *iface)
{
WshExecImpl *This = impl_from_IWshExec(iface);
LONG ref = InterlockedDecrement(&This->ref);
- TRACE("(%p) ref = %d\n", This, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref) {
CloseHandle(This->info.hThread);
@@ -145,19 +145,18 @@ static HRESULT WINAPI WshExec_GetTypeInfoCount(IWshExec *iface, UINT *pctinfo)
static HRESULT WINAPI WshExec_GetTypeInfo(IWshExec *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
{
- WshExecImpl *This = impl_from_IWshExec(iface);
- TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
+
return get_typeinfo(IWshExec_tid, ppTInfo);
}
static HRESULT WINAPI WshExec_GetIDsOfNames(IWshExec *iface, REFIID riid, LPOLESTR *rgszNames,
UINT cNames, LCID lcid, DISPID *rgDispId)
{
- WshExecImpl *This = impl_from_IWshExec(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IWshExec_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -172,18 +171,16 @@ static HRESULT WINAPI WshExec_GetIDsOfNames(IWshExec *iface, REFIID riid, LPOLES
static HRESULT WINAPI WshExec_Invoke(IWshExec *iface, DISPID dispIdMember, REFIID riid, LCID lcid,
WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- WshExecImpl *This = impl_from_IWshExec(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IWshExec_tid, &typeinfo);
if(SUCCEEDED(hr))
{
- hr = ITypeInfo_Invoke(typeinfo, &This->IWshExec_iface, dispIdMember, wFlags,
- pDispParams, pVarResult, pExcepInfo, puArgErr);
+ hr = ITypeInfo_Invoke(typeinfo, iface, dispIdMember, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
ITypeInfo_Release(typeinfo);
}
@@ -372,7 +369,7 @@ static ULONG WINAPI WshEnvironment_AddRef(IWshEnvironment *iface)
{
WshEnvironment *This = impl_from_IWshEnvironment(iface);
LONG ref = InterlockedIncrement(&This->ref);
- TRACE("(%p) ref = %d\n", This, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
return ref;
}
@@ -380,7 +377,7 @@ static ULONG WINAPI WshEnvironment_Release(IWshEnvironment *iface)
{
WshEnvironment *This = impl_from_IWshEnvironment(iface);
LONG ref = InterlockedDecrement(&This->ref);
- TRACE("(%p) ref = %d\n", This, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
free(This);
@@ -398,19 +395,18 @@ static HRESULT WINAPI WshEnvironment_GetTypeInfoCount(IWshEnvironment *iface, UI
static HRESULT WINAPI WshEnvironment_GetTypeInfo(IWshEnvironment *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
{
- WshEnvironment *This = impl_from_IWshEnvironment(iface);
- TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
+
return get_typeinfo(IWshEnvironment_tid, ppTInfo);
}
static HRESULT WINAPI WshEnvironment_GetIDsOfNames(IWshEnvironment *iface, REFIID riid, LPOLESTR *rgszNames,
UINT cNames, LCID lcid, DISPID *rgDispId)
{
- WshEnvironment *This = impl_from_IWshEnvironment(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IWshEnvironment_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -425,18 +421,16 @@ static HRESULT WINAPI WshEnvironment_GetIDsOfNames(IWshEnvironment *iface, REFII
static HRESULT WINAPI WshEnvironment_Invoke(IWshEnvironment *iface, DISPID dispIdMember, REFIID riid, LCID lcid,
WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- WshEnvironment *This = impl_from_IWshEnvironment(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IWshEnvironment_tid, &typeinfo);
if(SUCCEEDED(hr))
{
- hr = ITypeInfo_Invoke(typeinfo, &This->IWshEnvironment_iface, dispIdMember, wFlags,
- pDispParams, pVarResult, pExcepInfo, puArgErr);
+ hr = ITypeInfo_Invoke(typeinfo, iface, dispIdMember, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
ITypeInfo_Release(typeinfo);
}
@@ -561,20 +555,22 @@ static HRESULT WINAPI WshCollection_QueryInterface(IWshCollection *iface, REFIID
static ULONG WINAPI WshCollection_AddRef(IWshCollection *iface)
{
- WshCollection *This = impl_from_IWshCollection(iface);
- LONG ref = InterlockedIncrement(&This->ref);
- TRACE("(%p) ref = %d\n", This, ref);
+ WshCollection *collection = impl_from_IWshCollection(iface);
+ LONG ref = InterlockedIncrement(&collection->ref);
+
+ TRACE("%p, refcount %ld.\n", iface, ref);
+
return ref;
}
static ULONG WINAPI WshCollection_Release(IWshCollection *iface)
{
- WshCollection *This = impl_from_IWshCollection(iface);
- LONG ref = InterlockedDecrement(&This->ref);
- TRACE("(%p) ref = %d\n", This, ref);
+ WshCollection *collection = impl_from_IWshCollection(iface);
+ LONG ref = InterlockedDecrement(&collection->ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
- free(This);
+ free(collection);
return ref;
}
@@ -589,19 +585,18 @@ static HRESULT WINAPI WshCollection_GetTypeInfoCount(IWshCollection *iface, UINT
static HRESULT WINAPI WshCollection_GetTypeInfo(IWshCollection *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
{
- WshCollection *This = impl_from_IWshCollection(iface);
- TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
+
return get_typeinfo(IWshCollection_tid, ppTInfo);
}
static HRESULT WINAPI WshCollection_GetIDsOfNames(IWshCollection *iface, REFIID riid, LPOLESTR *rgszNames,
UINT cNames, LCID lcid, DISPID *rgDispId)
{
- WshCollection *This = impl_from_IWshCollection(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IWshCollection_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -616,18 +611,16 @@ static HRESULT WINAPI WshCollection_GetIDsOfNames(IWshCollection *iface, REFIID
static HRESULT WINAPI WshCollection_Invoke(IWshCollection *iface, DISPID dispIdMember, REFIID riid, LCID lcid,
WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- WshCollection *This = impl_from_IWshCollection(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IWshCollection_tid, &typeinfo);
if(SUCCEEDED(hr))
{
- hr = ITypeInfo_Invoke(typeinfo, &This->IWshCollection_iface, dispIdMember, wFlags,
- pDispParams, pVarResult, pExcepInfo, puArgErr);
+ hr = ITypeInfo_Invoke(typeinfo, iface, dispIdMember, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
ITypeInfo_Release(typeinfo);
}
@@ -763,7 +756,7 @@ static ULONG WINAPI WshShortcut_AddRef(IWshShortcut *iface)
{
WshShortcut *This = impl_from_IWshShortcut(iface);
LONG ref = InterlockedIncrement(&This->ref);
- TRACE("(%p) ref = %d\n", This, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
return ref;
}
@@ -771,7 +764,7 @@ static ULONG WINAPI WshShortcut_Release(IWshShortcut *iface)
{
WshShortcut *This = impl_from_IWshShortcut(iface);
LONG ref = InterlockedDecrement(&This->ref);
- TRACE("(%p) ref = %d\n", This, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
{
@@ -793,19 +786,18 @@ static HRESULT WINAPI WshShortcut_GetTypeInfoCount(IWshShortcut *iface, UINT *pc
static HRESULT WINAPI WshShortcut_GetTypeInfo(IWshShortcut *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
{
- WshShortcut *This = impl_from_IWshShortcut(iface);
- TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
+
return get_typeinfo(IWshShortcut_tid, ppTInfo);
}
static HRESULT WINAPI WshShortcut_GetIDsOfNames(IWshShortcut *iface, REFIID riid, LPOLESTR *rgszNames,
UINT cNames, LCID lcid, DISPID *rgDispId)
{
- WshShortcut *This = impl_from_IWshShortcut(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IWshShortcut_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -820,18 +812,16 @@ static HRESULT WINAPI WshShortcut_GetIDsOfNames(IWshShortcut *iface, REFIID riid
static HRESULT WINAPI WshShortcut_Invoke(IWshShortcut *iface, DISPID dispIdMember, REFIID riid, LCID lcid,
WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- WshShortcut *This = impl_from_IWshShortcut(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IWshShortcut_tid, &typeinfo);
if(SUCCEEDED(hr))
{
- hr = ITypeInfo_Invoke(typeinfo, &This->IWshShortcut_iface, dispIdMember, wFlags,
- pDispParams, pVarResult, pExcepInfo, puArgErr);
+ hr = ITypeInfo_Invoke(typeinfo, iface, dispIdMember, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
ITypeInfo_Release(typeinfo);
}
@@ -1155,7 +1145,8 @@ static HRESULT WINAPI WshShell3_GetTypeInfoCount(IWshShell3 *iface, UINT *pctinf
static HRESULT WINAPI WshShell3_GetTypeInfo(IWshShell3 *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
{
- TRACE("(%u %u %p)\n", iTInfo, lcid, ppTInfo);
+ TRACE("%u, %lx, %p.\n", iTInfo, lcid, ppTInfo);
+
return get_typeinfo(IWshShell3_tid, ppTInfo);
}
@@ -1165,7 +1156,7 @@ static HRESULT WINAPI WshShell3_GetIDsOfNames(IWshShell3 *iface, REFIID riid, LP
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%s %p %u %u %p)\n", debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%s, %p, %u, %lx, %p.\n", debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IWshShell3_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -1183,7 +1174,7 @@ static HRESULT WINAPI WshShell3_Invoke(IWshShell3 *iface, DISPID dispIdMember, R
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%d %s %d %d %p %p %p %p)\n", dispIdMember, debugstr_guid(riid),
+ TRACE("%ld, %s, %lx, %d, %p, %p, %p, %p.\n", dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IWshShell3_tid, &typeinfo);
@@ -1255,7 +1246,7 @@ static HRESULT WINAPI WshShell3_Run(IWshShell3 *iface, BSTR cmd, VARIANT *style,
hr = VariantChangeType(&s, style, 0, VT_I4);
if (FAILED(hr))
{
- ERR("failed to convert style argument, 0x%08x\n", hr);
+ ERR("failed to convert style argument, %#lx\n", hr);
return hr;
}
@@ -1285,7 +1276,7 @@ static HRESULT WINAPI WshShell3_Run(IWshShell3 *iface, BSTR cmd, VARIANT *style,
free(file);
if (!ret)
{
- TRACE("ShellExecute failed, %d\n", GetLastError());
+ TRACE("ShellExecute failed, %ld\n", GetLastError());
return HRESULT_FROM_WIN32(GetLastError());
}
else
@@ -1587,7 +1578,7 @@ static HRESULT WINAPI WshShell3_RegRead(IWshShell3 *iface, BSTR name, VARIANT *v
break;
}
default:
- FIXME("value type %d not supported\n", type);
+ FIXME("value type %ld not supported\n", type);
hr = E_FAIL;
};
@@ -1663,12 +1654,12 @@ static HRESULT WINAPI WshShell3_RegWrite(IWshShell3 *iface, BSTR name, VARIANT *
data_len = sizeof(DWORD);
break;
default:
- FIXME("unexpected regtype %d\n", regtype);
+ FIXME("unexpected regtype %ld\n", regtype);
return E_FAIL;
};
if (FAILED(hr)) {
- FIXME("failed to convert value, regtype %d, 0x%08x\n", regtype, hr);
+ FIXME("failed to convert value, regtype %ld, %#lx.\n", regtype, hr);
return hr;
}
diff --git a/dlls/wshom.ocx/wshom_main.c b/dlls/wshom.ocx/wshom_main.c
index 0439ceb072a..b2dc79a1948 100644
--- a/dlls/wshom.ocx/wshom_main.c
+++ b/dlls/wshom.ocx/wshom_main.c
@@ -53,7 +53,7 @@ static HRESULT load_typelib(void)
hres = LoadRegTypeLib(&LIBID_IWshRuntimeLibrary, 1, 0, LOCALE_SYSTEM_DEFAULT, &tl);
if(FAILED(hres)) {
- ERR("LoadRegTypeLib failed: %08x\n", hres);
+ ERR("LoadRegTypeLib failed: %#lx.\n", hres);
return hres;
}
@@ -84,7 +84,7 @@ HRESULT get_typeinfo(tid_t tid, ITypeInfo **typeinfo)
hres = ITypeLib_GetTypeInfoOfGuid(typelib, tid_ids[tid], &ti);
if(FAILED(hres)) {
- ERR("GetTypeInfoOfGuid(%s) failed: %08x\n", debugstr_guid(tid_ids[tid]), hres);
+ ERR("GetTypeInfoOfGuid(%s) failed: %#lx.\n", debugstr_guid(tid_ids[tid]), hres);
return hres;
}
@@ -216,7 +216,7 @@ static IClassFactory WshShellFactory = { &WshShellFactoryVtbl };
*/
BOOL WINAPI DllMain(HINSTANCE hInstDLL, DWORD fdwReason, LPVOID lpv)
{
- TRACE("(%p %d %p)\n", hInstDLL, fdwReason, lpv);
+ TRACE("%p, %ld, %p.\n", hInstDLL, fdwReason, lpv);
switch(fdwReason)
{
--
2.34.1
1
0
[PATCH 1/4] d3d9/tests: Try to make test_cursor_pos more reliable.
by Stefan Dösinger Jan. 31, 2022
by Stefan Dösinger Jan. 31, 2022
Jan. 31, 2022
Signed-off-by: Stefan Dösinger <stefan(a)codeweavers.com>
---
The Win10 1709 behavior and apparent workaround of moving the pointer
before the test don't quite make sense. In past testbot runs there have
been cases where e.g. move 3 doesn't produce a message, or any other
move. This patch has worked so far in all of my manual testbot
submissions. The only way to know is to wait and see...
I have sent this series on top of 225041 and 225042, but it should apply
independently as well.
---
dlls/d3d9/tests/device.c | 24 ++++++++++++++++++++----
1 file changed, 20 insertions(+), 4 deletions(-)
diff --git a/dlls/d3d9/tests/device.c b/dlls/d3d9/tests/device.c
index 7effd0f28b8..9c2e94cc694 100644
--- a/dlls/d3d9/tests/device.c
+++ b/dlls/d3d9/tests/device.c
@@ -5205,6 +5205,20 @@ static void test_cursor_pos(void)
{0, 0},
};
+ /* Windows 10 1709 is unreliable. One or more of the cursor movements we
+ * expect don't show up. Moving the mouse to a defined position beforehand
+ * seems to get it into better shape - only the final 150x150 move we do
+ * below is missing - it looks as if this Windows version filters redundant
+ * SetCursorPos calls on the user32 level, although I am not entirely sure.
+ *
+ * The weird thing is that the previous test leaves the cursor position
+ * reliably at 512x384 on the testbot. So the 50x50 mouse move shouldn't
+ * be stripped away anyway, but it might be a difference between moving the
+ * cursor through SetCursorPos vs moving it by changing the display mode. */
+ ret = SetCursorPos(99, 99);
+ ok(ret, "Failed to set cursor position.\n");
+ flush_events();
+
wc.lpfnWndProc = test_cursor_proc;
wc.lpszClassName = "d3d9_test_cursor_wc";
ok(RegisterClassA(&wc), "Failed to register window class.\n");
@@ -5239,7 +5253,8 @@ static void test_cursor_pos(void)
IDirect3DDevice9_SetCursorPosition(device, 75, 75, 0);
flush_events();
- /* SetCursorPosition() eats duplicates. */
+ /* SetCursorPosition() eats duplicates. FIXME: Since we accept unexpected
+ * mouse moves the test doesn't actually demonstrate that. */
IDirect3DDevice9_SetCursorPosition(device, 75, 75, 0);
flush_events();
@@ -5260,13 +5275,14 @@ static void test_cursor_pos(void)
IDirect3DDevice9_SetCursorPosition(device, 150, 150, 0);
flush_events();
- /* SetCursorPos() doesn't. */
+ /* SetCursorPos() doesn't. Except for Win10 1709. */
ret = SetCursorPos(150, 150);
ok(ret, "Failed to set cursor position.\n");
flush_events();
- ok(!expect_pos->x && !expect_pos->y, "Didn't receive MOUSEMOVE %u (%d, %d).\n",
- (unsigned)(expect_pos - points), expect_pos->x, expect_pos->y);
+ ok((!expect_pos->x && !expect_pos->y) || broken(expect_pos - points == 7),
+ "Didn't receive MOUSEMOVE %u (%d, %d).\n",
+ (unsigned)(expect_pos - points), expect_pos->x, expect_pos->y);
refcount = IDirect3DDevice9_Release(device);
ok(!refcount, "Device has %u references left.\n", refcount);
--
2.34.1
4
14
[PATCH 1/2] d3d9/tests: Ignore random testbot failures in test_cursor.
by Stefan Dösinger Jan. 31, 2022
by Stefan Dösinger Jan. 31, 2022
Jan. 31, 2022
Signed-off-by: Stefan Dösinger <stefan(a)codeweavers.com>
---
dlls/d3d9/tests/device.c | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/dlls/d3d9/tests/device.c b/dlls/d3d9/tests/device.c
index c480a9d163e..7effd0f28b8 100644
--- a/dlls/d3d9/tests/device.c
+++ b/dlls/d3d9/tests/device.c
@@ -1886,11 +1886,19 @@ static void test_cursor(void)
IDirect3DSurface9_Release(cursor);
+ /* On the testbot the cursor handle does not behave as expected in rare situations,
+ * leading to random test failures. Either the cursor handle changes before we expect
+ * it to, or it doesn't change afterwards (or already changed before we read the
+ * initial handle?). I was not able to reproduce this on my own machines. Moving the
+ * mouse outside the window results in similar behavior. However, I tested various
+ * obvious failure causes: Was the mouse moved? Was the window hidden or moved? Is
+ * the window in the background? Neither of those applies. Making the window topmost
+ * or using a fullscreen device doesn't improve the test's reliability either. */
memset(&info, 0, sizeof(info));
info.cbSize = sizeof(info);
ok(GetCursorInfo(&info), "GetCursorInfo failed\n");
ok(info.flags & (CURSOR_SHOWING|CURSOR_SUPPRESSED), "The gdi cursor is hidden (%08x)\n", info.flags);
- ok(info.hCursor == cur, "The cursor handle is %p\n", info.hCursor); /* unchanged */
+ ok(info.hCursor == cur || broken(1), "The cursor handle is %p\n", info.hCursor); /* unchanged */
/* Still hidden */
ret = IDirect3DDevice9_ShowCursor(device, TRUE);
@@ -1904,7 +1912,7 @@ static void test_cursor(void)
info.cbSize = sizeof(info);
ok(GetCursorInfo(&info), "GetCursorInfo failed\n");
ok(info.flags & (CURSOR_SHOWING|CURSOR_SUPPRESSED), "The gdi cursor is hidden (%08x)\n", info.flags);
- ok(info.hCursor != cur, "The cursor handle is %p\n", info.hCursor);
+ ok(info.hCursor != cur || broken(1), "The cursor handle is %p\n", info.hCursor);
/* Cursor dimensions must all be powers of two */
for (test_idx = 0; test_idx < ARRAY_SIZE(cursor_sizes); ++test_idx)
--
2.34.1
3
5
[tools] testbot/SetWinLocale: Take --reboot into account when checking the results.
by Francois Gouget Jan. 31, 2022
by Francois Gouget Jan. 31, 2022
Jan. 31, 2022
Don't complain about settings that are only modified after a reboot if
none took place.
Signed-off-by: Francois Gouget <fgouget(a)codeweavers.com>
---
testbot/bin/SetWinLocale | 23 +++++++++++++++++++++--
1 file changed, 21 insertions(+), 2 deletions(-)
diff --git a/testbot/bin/SetWinLocale b/testbot/bin/SetWinLocale
index 2ff8348fb3..6535c49396 100755
--- a/testbot/bin/SetWinLocale
+++ b/testbot/bin/SetWinLocale
@@ -904,7 +904,19 @@ if ($OptUTF8)
}
if ($OptMUI)
{
- CheckSetting($Settings, "PreferredUILanguages", $OptMUI, "for --mui $OptMUI");
+ if ($OptReboot)
+ {
+ CheckSetting($Settings, "PreferredUILanguages", $OptMUI, "for --mui $OptMUI");
+ if ($Settings->{PreferredUILanguagesPending})
+ {
+ Error("PreferredUILanguagesPending should not be set for --mui $OptMUI\n");
+ $Success = 0;
+ }
+ }
+ else
+ {
+ CheckSetting($Settings, "PreferredUILanguagesPending", $OptMUI, "for --mui $OptMUI");
+ }
}
if ($KeyboardIds)
{
@@ -923,7 +935,7 @@ if ($OptSysCopy)
CheckSetting($Settings, "DefCountry", $CountryId, "for --country $OptCountry");
CheckSetting($Settings, "DefCountryName", $OptCountry, "for --country $OptCountry");
}
- if ($OptMUI)
+ if ($OptMUI and $OptReboot)
{
CheckSetting($Settings, "DefMachinePreferredUILanguages", $OptMUI, "for --mui $OptMUI");
}
@@ -932,6 +944,13 @@ if ($OptSysCopy)
CheckSetting($Settings, "DefInputMethod", $KeyboardIds->[0], "for --keyboard $OptKeyboard", 1);
}
}
+if (!$OptReboot and ($OptSystem or $OptMUI))
+{
+ my @Pending;
+ push @Pending, "--system $OptSystem" if ($OptSystem);
+ push @Pending, "--mui $OptMUI" if ($OptMUI);
+ Warning(join(" ", "the", @Pending, "changes are still pending\n"));
+}
Cleanup();
exit(1) if (!$Success);
--
2.30.2
1
0
Jan. 31, 2022
Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com>
---
dlls/mf/tests/mf.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/dlls/mf/tests/mf.c b/dlls/mf/tests/mf.c
index dede008fbd9..8ba93656a7d 100644
--- a/dlls/mf/tests/mf.c
+++ b/dlls/mf/tests/mf.c
@@ -1562,7 +1562,7 @@ static ULONG WINAPI test_source_Release(IMFMediaSource *iface)
ULONG refcount = InterlockedDecrement(&source->refcount);
if (!refcount)
- HeapFree(GetProcessHeap(), 0, source);
+ free(source);
return refcount;
}
@@ -1650,7 +1650,7 @@ static IMFMediaSource *create_test_source(void)
{
struct test_source *source;
- source = HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, sizeof(*source));
+ source = calloc(1, sizeof(*source));
source->IMFMediaSource_iface.lpVtbl = &test_source_vtbl;
source->refcount = 1;
--
2.34.1
1
0
Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com>
---
dlls/rtworkq/Makefile.in | 1 -
dlls/rtworkq/queue.c | 58 ++++++++++++++++++++--------------------
2 files changed, 29 insertions(+), 30 deletions(-)
diff --git a/dlls/rtworkq/Makefile.in b/dlls/rtworkq/Makefile.in
index d5aa5ec0d0f..46268866ddb 100644
--- a/dlls/rtworkq/Makefile.in
+++ b/dlls/rtworkq/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = rtworkq.dll
IMPORTLIB = rtworkq
IMPORTS = ole32
diff --git a/dlls/rtworkq/queue.c b/dlls/rtworkq/queue.c
index 58769a0be04..35ba1e28d03 100644
--- a/dlls/rtworkq/queue.c
+++ b/dlls/rtworkq/queue.c
@@ -426,7 +426,7 @@ static void CALLBACK serial_queue_finalization_callback(PTP_CALLBACK_INSTANCE in
if (SUCCEEDED(hr = grab_queue(queue->target_queue, &target_queue)))
target_queue->ops->submit(target_queue, next_item);
else
- WARN("Failed to grab queue for id %#x, hr %#x.\n", queue->target_queue, hr);
+ WARN("Failed to grab queue for id %#lx, hr %#lx.\n", queue->target_queue, hr);
}
LeaveCriticalSection(&queue->cs);
@@ -478,7 +478,7 @@ static void serial_queue_submit(struct queue *queue, struct work_item *item)
if (item->flags & RTWQ_REPLY_CALLBACK)
{
if (FAILED(hr = RtwqCreateAsyncResult(NULL, &queue->IRtwqAsyncCallback_iface, NULL, &item->reply_result)))
- WARN("Failed to create reply object, hr %#x.\n", hr);
+ WARN("Failed to create reply object, hr %#lx.\n", hr);
}
else
item->finalization_callback = queue->finalization_callback;
@@ -512,7 +512,7 @@ static void serial_queue_submit(struct queue *queue, struct work_item *item)
if (SUCCEEDED(hr = grab_queue(queue->target_queue, &target_queue)))
target_queue->ops->submit(target_queue, next_item);
else
- WARN("Failed to grab queue for id %#x, hr %#x.\n", queue->target_queue, hr);
+ WARN("Failed to grab queue for id %#lx, hr %#lx.\n", queue->target_queue, hr);
}
LeaveCriticalSection(&queue->cs);
@@ -875,7 +875,7 @@ static HRESULT queue_cancel_item(struct queue *queue, RTWQWORKITEM_KEY key)
else if ((key & SCHEDULED_ITEM_KEY_MASK) == SCHEDULED_ITEM_KEY_MASK)
CloseThreadpoolTimer(item->u.timer_object);
else
- WARN("Unknown item key mask %#x.\n", (DWORD)key);
+ WARN("Unknown item key mask %#lx.\n", (DWORD)key);
queue_release_pending_item(item);
hr = S_OK;
break;
@@ -964,7 +964,7 @@ static ULONG WINAPI async_result_AddRef(IRtwqAsyncResult *iface)
struct async_result *result = impl_from_IRtwqAsyncResult(iface);
ULONG refcount = InterlockedIncrement(&result->refcount);
- TRACE("%p, %u.\n", iface, refcount);
+ TRACE("%p, %lu.\n", iface, refcount);
return refcount;
}
@@ -974,7 +974,7 @@ static ULONG WINAPI async_result_Release(IRtwqAsyncResult *iface)
struct async_result *result = impl_from_IRtwqAsyncResult(iface);
ULONG refcount = InterlockedDecrement(&result->refcount);
- TRACE("%p, %u.\n", iface, refcount);
+ TRACE("%p, %lu.\n", iface, refcount);
if (!refcount)
{
@@ -1022,7 +1022,7 @@ static HRESULT WINAPI async_result_SetStatus(IRtwqAsyncResult *iface, HRESULT st
{
struct async_result *result = impl_from_IRtwqAsyncResult(iface);
- TRACE("%p, %#x.\n", iface, status);
+ TRACE("%p, %#lx.\n", iface, status);
result->result.hrStatusResult = status;
@@ -1134,7 +1134,7 @@ static void init_system_queues(void)
}
if (FAILED(hr = CoIncrementMTAUsage(&mta_cookie)))
- WARN("Failed to initialize MTA, hr %#x.\n", hr);
+ WARN("Failed to initialize MTA, hr %#lx.\n", hr);
desc.queue_type = RTWQ_STANDARD_WORKQUEUE;
desc.ops = &pool_queue_ops;
@@ -1167,7 +1167,7 @@ static void shutdown_system_queues(void)
}
if (FAILED(hr = CoDecrementMTAUsage(mta_cookie)))
- WARN("Failed to uninitialize MTA, hr %#x.\n", hr);
+ WARN("Failed to uninitialize MTA, hr %#lx.\n", hr);
LeaveCriticalSection(&queues_section);
}
@@ -1190,7 +1190,7 @@ HRESULT WINAPI RtwqPutWaitingWorkItem(HANDLE event, LONG priority, IRtwqAsyncRes
struct queue *queue;
HRESULT hr;
- TRACE("%p, %d, %p, %p.\n", event, priority, result, key);
+ TRACE("%p, %ld, %p, %p.\n", event, priority, result, key);
if (FAILED(hr = grab_queue(RTWQ_CALLBACK_QUEUE_TIMER, &queue)))
return hr;
@@ -1251,7 +1251,7 @@ static ULONG WINAPI periodic_callback_AddRef(IRtwqAsyncCallback *iface)
struct periodic_callback *callback = impl_from_IRtwqAsyncCallback(iface);
ULONG refcount = InterlockedIncrement(&callback->refcount);
- TRACE("%p, %u.\n", iface, refcount);
+ TRACE("%p, %lu.\n", iface, refcount);
return refcount;
}
@@ -1261,7 +1261,7 @@ static ULONG WINAPI periodic_callback_Release(IRtwqAsyncCallback *iface)
struct periodic_callback *callback = impl_from_IRtwqAsyncCallback(iface);
ULONG refcount = InterlockedDecrement(&callback->refcount);
- TRACE("%p, %u.\n", iface, refcount);
+ TRACE("%p, %lu.\n", iface, refcount);
if (!refcount)
free(callback);
@@ -1352,7 +1352,7 @@ HRESULT WINAPI RtwqRemovePeriodicCallback(DWORD key)
struct queue *queue;
HRESULT hr;
- TRACE("%#x.\n", key);
+ TRACE("%#lx.\n", key);
if (FAILED(hr = grab_queue(RTWQ_CALLBACK_QUEUE_TIMER, &queue)))
return hr;
@@ -1382,7 +1382,7 @@ HRESULT WINAPI RtwqInvokeCallback(IRtwqAsyncResult *result)
HRESULT WINAPI RtwqPutWorkItem(DWORD queue, LONG priority, IRtwqAsyncResult *result)
{
- TRACE("%#x, %d, %p.\n", queue, priority, result);
+ TRACE("%#lx, %ld, %p.\n", queue, priority, result);
return queue_put_work_item(queue, priority, result);
}
@@ -1401,14 +1401,14 @@ HRESULT WINAPI RtwqAllocateWorkQueue(RTWQ_WORKQUEUE_TYPE queue_type, DWORD *queu
HRESULT WINAPI RtwqLockWorkQueue(DWORD queue)
{
- TRACE("%#x.\n", queue);
+ TRACE("%#lx.\n", queue);
return lock_user_queue(queue);
}
HRESULT WINAPI RtwqUnlockWorkQueue(DWORD queue)
{
- TRACE("%#x.\n", queue);
+ TRACE("%#lx.\n", queue);
return unlock_user_queue(queue);
}
@@ -1419,7 +1419,7 @@ HRESULT WINAPI RtwqSetLongRunning(DWORD queue_id, BOOL enable)
HRESULT hr;
int i;
- TRACE("%#x, %d.\n", queue_id, enable);
+ TRACE("%#lx, %d.\n", queue_id, enable);
lock_user_queue(queue_id);
@@ -1439,7 +1439,7 @@ HRESULT WINAPI RtwqLockSharedWorkQueue(const WCHAR *usageclass, LONG priority, D
struct queue_desc desc;
HRESULT hr;
- TRACE("%s, %d, %p, %p.\n", debugstr_w(usageclass), priority, taskid, queue);
+ TRACE("%s, %ld, %p, %p.\n", debugstr_w(usageclass), priority, taskid, queue);
if (!usageclass)
return E_POINTER;
@@ -1471,14 +1471,14 @@ HRESULT WINAPI RtwqLockSharedWorkQueue(const WCHAR *usageclass, LONG priority, D
HRESULT WINAPI RtwqSetDeadline(DWORD queue_id, LONGLONG deadline, HANDLE *request)
{
- FIXME("%#x, %s, %p.\n", queue_id, wine_dbgstr_longlong(deadline), request);
+ FIXME("%#lx, %s, %p.\n", queue_id, wine_dbgstr_longlong(deadline), request);
return E_NOTIMPL;
}
HRESULT WINAPI RtwqSetDeadline2(DWORD queue_id, LONGLONG deadline, LONGLONG predeadline, HANDLE *request)
{
- FIXME("%#x, %s, %s, %p.\n", queue_id, wine_dbgstr_longlong(deadline), wine_dbgstr_longlong(predeadline), request);
+ FIXME("%#lx, %s, %s, %p.\n", queue_id, wine_dbgstr_longlong(deadline), wine_dbgstr_longlong(predeadline), request);
return E_NOTIMPL;
}
@@ -1494,7 +1494,7 @@ HRESULT WINAPI RtwqAllocateSerialWorkQueue(DWORD target_queue, DWORD *queue)
{
struct queue_desc desc;
- TRACE("%#x, %p.\n", target_queue, queue);
+ TRACE("%#lx, %p.\n", target_queue, queue);
desc.queue_type = RTWQ_STANDARD_WORKQUEUE;
desc.ops = &serial_queue_ops;
@@ -1504,42 +1504,42 @@ HRESULT WINAPI RtwqAllocateSerialWorkQueue(DWORD target_queue, DWORD *queue)
HRESULT WINAPI RtwqJoinWorkQueue(DWORD queue, HANDLE hFile, HANDLE *cookie)
{
- FIXME("%#x, %p, %p.\n", queue, hFile, cookie);
+ FIXME("%#lx, %p, %p.\n", queue, hFile, cookie);
return E_NOTIMPL;
}
HRESULT WINAPI RtwqUnjoinWorkQueue(DWORD queue, HANDLE cookie)
{
- FIXME("%#x, %p.\n", queue, cookie);
+ FIXME("%#lx, %p.\n", queue, cookie);
return E_NOTIMPL;
}
HRESULT WINAPI RtwqGetWorkQueueMMCSSClass(DWORD queue, WCHAR *class, DWORD *length)
{
- FIXME("%#x, %p, %p.\n", queue, class, length);
+ FIXME("%#lx, %p, %p.\n", queue, class, length);
return E_NOTIMPL;
}
HRESULT WINAPI RtwqGetWorkQueueMMCSSTaskId(DWORD queue, DWORD *taskid)
{
- FIXME("%#x, %p.\n", queue, taskid);
+ FIXME("%#lx, %p.\n", queue, taskid);
return E_NOTIMPL;
}
HRESULT WINAPI RtwqGetWorkQueueMMCSSPriority(DWORD queue, LONG *priority)
{
- FIXME("%#x, %p.\n", queue, priority);
+ FIXME("%#lx, %p.\n", queue, priority);
return E_NOTIMPL;
}
HRESULT WINAPI RtwqRegisterPlatformWithMMCSS(const WCHAR *class, DWORD *taskid, LONG priority)
{
- FIXME("%s, %p, %d.\n", debugstr_w(class), taskid, priority);
+ FIXME("%s, %p, %ld.\n", debugstr_w(class), taskid, priority);
return E_NOTIMPL;
}
@@ -1554,7 +1554,7 @@ HRESULT WINAPI RtwqUnregisterPlatformFromMMCSS(void)
HRESULT WINAPI RtwqBeginRegisterWorkQueueWithMMCSS(DWORD queue, const WCHAR *class, DWORD taskid, LONG priority,
IRtwqAsyncCallback *callback, IUnknown *state)
{
- FIXME("%#x, %s, %u, %d, %p, %p.\n", queue, debugstr_w(class), taskid, priority, callback, state);
+ FIXME("%#lx, %s, %lu, %ld, %p, %p.\n", queue, debugstr_w(class), taskid, priority, callback, state);
return E_NOTIMPL;
}
@@ -1568,7 +1568,7 @@ HRESULT WINAPI RtwqEndRegisterWorkQueueWithMMCSS(IRtwqAsyncResult *result, DWORD
HRESULT WINAPI RtwqBeginUnregisterWorkQueueWithMMCSS(DWORD queue, IRtwqAsyncCallback *callback, IUnknown *state)
{
- FIXME("%#x, %p, %p.\n", queue, callback, state);
+ FIXME("%#lx, %p, %p.\n", queue, callback, state);
return E_NOTIMPL;
}
--
2.34.1
1
0
Signed-off-by: Nikolay Sivov <nsivov(a)codeweavers.com>
---
dlls/scrrun/Makefile.in | 1 -
dlls/scrrun/dictionary.c | 22 ++--
dlls/scrrun/filesystem.c | 216 ++++++++++++++++++++-------------------
dlls/scrrun/scrrun.c | 6 +-
4 files changed, 122 insertions(+), 123 deletions(-)
diff --git a/dlls/scrrun/Makefile.in b/dlls/scrrun/Makefile.in
index c0beae245ef..31ef016f48e 100644
--- a/dlls/scrrun/Makefile.in
+++ b/dlls/scrrun/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = scrrun.dll
IMPORTS = uuid oleaut32 version advapi32
diff --git a/dlls/scrrun/dictionary.c b/dlls/scrrun/dictionary.c
index d1c6eb24e0b..bb9c3610d1b 100644
--- a/dlls/scrrun/dictionary.c
+++ b/dlls/scrrun/dictionary.c
@@ -240,7 +240,7 @@ static ULONG WINAPI dict_enum_AddRef(IEnumVARIANT *iface)
{
struct dictionary_enum *This = impl_from_IEnumVARIANT(iface);
ULONG ref = InterlockedIncrement(&This->ref);
- TRACE("(%p)->(%u)\n", This, ref);
+ TRACE("%p, refcount %lu.\n", iface, ref);
return ref;
}
@@ -249,7 +249,7 @@ static ULONG WINAPI dict_enum_Release(IEnumVARIANT *iface)
struct dictionary_enum *This = impl_from_IEnumVARIANT(iface);
LONG ref = InterlockedDecrement(&This->ref);
- TRACE("(%p)->(%u)\n", This, ref);
+ TRACE("%p, refcount %lu.\n", iface, ref);
if (!ref)
{
@@ -267,7 +267,7 @@ static HRESULT WINAPI dict_enum_Next(IEnumVARIANT *iface, ULONG count, VARIANT *
struct keyitem_pair *pair;
ULONG i = 0;
- TRACE("(%p)->(%u %p %p)\n", This, count, keys, fetched);
+ TRACE("%p, %lu, %p, %p.\n", iface, count, keys, fetched);
if (fetched)
*fetched = 0;
@@ -292,7 +292,7 @@ static HRESULT WINAPI dict_enum_Skip(IEnumVARIANT *iface, ULONG count)
{
struct dictionary_enum *This = impl_from_IEnumVARIANT(iface);
- TRACE("(%p)->(%u)\n", This, count);
+ TRACE("%p, %lu.\n", iface, count);
if (!count)
return S_OK;
@@ -418,7 +418,7 @@ static ULONG WINAPI dictionary_AddRef(IDictionary *iface)
struct dictionary *dictionary = impl_from_IDictionary(iface);
ULONG ref = InterlockedIncrement(&dictionary->ref);
- TRACE("%p, refcount %u.\n", iface, ref);
+ TRACE("%p, refcount %lu.\n", iface, ref);
return ref;
}
@@ -428,7 +428,7 @@ static ULONG WINAPI dictionary_Release(IDictionary *iface)
struct dictionary *dictionary = impl_from_IDictionary(iface);
ULONG ref = InterlockedDecrement(&dictionary->ref);
- TRACE("%p, refcount %u.\n", iface, ref);
+ TRACE("%p, refcount %lu.\n", iface, ref);
if (!ref)
{
@@ -449,7 +449,7 @@ static HRESULT WINAPI dictionary_GetTypeInfoCount(IDictionary *iface, UINT *pcti
static HRESULT WINAPI dictionary_GetTypeInfo(IDictionary *iface, UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
{
- TRACE("%p, %u, %u, %p.\n", iface, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
return get_typeinfo(IDictionary_tid, ppTInfo);
}
@@ -460,7 +460,7 @@ static HRESULT WINAPI dictionary_GetIDsOfNames(IDictionary *iface, REFIID riid,
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("%p, %s, %p, %u, %u, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IDictionary_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -476,18 +476,16 @@ static HRESULT WINAPI dictionary_Invoke(IDictionary *iface, DISPID dispIdMember,
LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult,
EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- struct dictionary *dictionary = impl_from_IDictionary(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("%p, %d, %s, %d, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IDictionary_tid, &typeinfo);
if(SUCCEEDED(hr))
{
- hr = ITypeInfo_Invoke(typeinfo, &dictionary->IDictionary_iface, dispIdMember, wFlags,
- pDispParams, pVarResult, pExcepInfo, puArgErr);
+ hr = ITypeInfo_Invoke(typeinfo, iface, dispIdMember, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
ITypeInfo_Release(typeinfo);
}
diff --git a/dlls/scrrun/filesystem.c b/dlls/scrrun/filesystem.c
index e525b9db8da..2b2255e1dfc 100644
--- a/dlls/scrrun/filesystem.c
+++ b/dlls/scrrun/filesystem.c
@@ -187,7 +187,7 @@ static inline HRESULT create_error(DWORD err)
case ERROR_FILE_EXISTS: return CTL_E_FILEALREADYEXISTS;
case ERROR_ALREADY_EXISTS: return CTL_E_FILEALREADYEXISTS;
default:
- FIXME("Unsupported error code: %d\n", err);
+ FIXME("Unsupported error code: %ld\n", err);
return E_FAIL;
}
}
@@ -308,9 +308,11 @@ static HRESULT WINAPI textstream_QueryInterface(ITextStream *iface, REFIID riid,
static ULONG WINAPI textstream_AddRef(ITextStream *iface)
{
- struct textstream *This = impl_from_ITextStream(iface);
- ULONG ref = InterlockedIncrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ struct textstream *stream = impl_from_ITextStream(iface);
+ ULONG ref = InterlockedIncrement(&stream->ref);
+
+ TRACE("%p, refcount %ld.\n", iface, ref);
+
return ref;
}
@@ -319,7 +321,7 @@ static ULONG WINAPI textstream_Release(ITextStream *iface)
struct textstream *stream = impl_from_ITextStream(iface);
ULONG ref = InterlockedDecrement(&stream->ref);
- TRACE("%p, refcount %d.\n", iface, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
{
@@ -342,8 +344,8 @@ static HRESULT WINAPI textstream_GetTypeInfoCount(ITextStream *iface, UINT *pcti
static HRESULT WINAPI textstream_GetTypeInfo(ITextStream *iface, UINT iTInfo,
LCID lcid, ITypeInfo **ppTInfo)
{
- struct textstream *This = impl_from_ITextStream(iface);
- TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
+
return get_typeinfo(ITextStream_tid, ppTInfo);
}
@@ -351,11 +353,10 @@ static HRESULT WINAPI textstream_GetIDsOfNames(ITextStream *iface, REFIID riid,
LPOLESTR *rgszNames, UINT cNames,
LCID lcid, DISPID *rgDispId)
{
- struct textstream *This = impl_from_ITextStream(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(ITextStream_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -372,11 +373,10 @@ static HRESULT WINAPI textstream_Invoke(ITextStream *iface, DISPID dispIdMember,
DISPPARAMS *pDispParams, VARIANT *pVarResult,
EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- struct textstream *This = impl_from_ITextStream(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(ITextStream_tid, &typeinfo);
@@ -513,7 +513,7 @@ static HRESULT WINAPI textstream_Read(ITextStream *iface, LONG len, BSTR *text)
struct textstream *This = impl_from_ITextStream(iface);
HRESULT hr = S_OK;
- TRACE("(%p)->(%d %p)\n", This, len, text);
+ TRACE("%p, %ld, %p.\n", iface, len, text);
if (!text)
return E_POINTER;
@@ -685,15 +685,15 @@ static HRESULT WINAPI textstream_WriteLine(ITextStream *iface, BSTR text)
static HRESULT WINAPI textstream_WriteBlankLines(ITextStream *iface, LONG lines)
{
- struct textstream *This = impl_from_ITextStream(iface);
- FIXME("(%p)->(%d): stub\n", This, lines);
+ FIXME("%p, %ld stub\n", iface, lines);
+
return E_NOTIMPL;
}
static HRESULT WINAPI textstream_Skip(ITextStream *iface, LONG count)
{
- struct textstream *This = impl_from_ITextStream(iface);
- FIXME("(%p)->(%d): stub\n", This, count);
+ FIXME("%p, %ld stub\n", iface, count);
+
return E_NOTIMPL;
}
@@ -866,9 +866,11 @@ static HRESULT WINAPI drive_QueryInterface(IDrive *iface, REFIID riid, void **ob
static ULONG WINAPI drive_AddRef(IDrive *iface)
{
- struct drive *This = impl_from_IDrive(iface);
- ULONG ref = InterlockedIncrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ struct drive *drive = impl_from_IDrive(iface);
+ ULONG ref = InterlockedIncrement(&drive->ref);
+
+ TRACE("%p, refcount %ld.\n", iface, ref);
+
return ref;
}
@@ -877,7 +879,7 @@ static ULONG WINAPI drive_Release(IDrive *iface)
struct drive *drive = impl_from_IDrive(iface);
ULONG ref = InterlockedDecrement(&drive->ref);
- TRACE("%p, refcount %d.\n", iface, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
free(drive);
@@ -896,8 +898,8 @@ static HRESULT WINAPI drive_GetTypeInfoCount(IDrive *iface, UINT *pctinfo)
static HRESULT WINAPI drive_GetTypeInfo(IDrive *iface, UINT iTInfo,
LCID lcid, ITypeInfo **ppTInfo)
{
- struct drive *This = impl_from_IDrive(iface);
- TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
+
return get_typeinfo(IDrive_tid, ppTInfo);
}
@@ -905,11 +907,10 @@ static HRESULT WINAPI drive_GetIDsOfNames(IDrive *iface, REFIID riid,
LPOLESTR *rgszNames, UINT cNames,
LCID lcid, DISPID *rgDispId)
{
- struct drive *This = impl_from_IDrive(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IDrive_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -926,11 +927,10 @@ static HRESULT WINAPI drive_Invoke(IDrive *iface, DISPID dispIdMember,
DISPPARAMS *pDispParams, VARIANT *pVarResult,
EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- struct drive *This = impl_from_IDrive(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IDrive_tid, &typeinfo);
@@ -1218,7 +1218,7 @@ static ULONG WINAPI enumvariant_AddRef(IEnumVARIANT *iface)
{
struct enumvariant *This = impl_from_IEnumVARIANT(iface);
ULONG ref = InterlockedIncrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
return ref;
}
@@ -1227,7 +1227,7 @@ static ULONG WINAPI foldercoll_enumvariant_Release(IEnumVARIANT *iface)
struct enumvariant *This = impl_from_IEnumVARIANT(iface);
ULONG ref = InterlockedDecrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
{
@@ -1274,7 +1274,7 @@ static HRESULT WINAPI foldercoll_enumvariant_Next(IEnumVARIANT *iface, ULONG cel
WIN32_FIND_DATAW data;
ULONG count = 0;
- TRACE("(%p)->(%d %p %p)\n", This, celt, var, fetched);
+ TRACE("%p, %lu, %p, %p.\n", iface, celt, var, fetched);
if (fetched)
*fetched = 0;
@@ -1327,7 +1327,7 @@ static HRESULT WINAPI foldercoll_enumvariant_Skip(IEnumVARIANT *iface, ULONG cel
HANDLE handle = This->data.u.foldercoll.find;
WIN32_FIND_DATAW data;
- TRACE("(%p)->(%d)\n", This, celt);
+ TRACE("%p, %lu.\n", iface, celt);
if (!celt) return S_OK;
@@ -1409,7 +1409,7 @@ static ULONG WINAPI filecoll_enumvariant_Release(IEnumVARIANT *iface)
struct enumvariant *This = impl_from_IEnumVARIANT(iface);
ULONG ref = InterlockedDecrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
{
@@ -1428,7 +1428,7 @@ static HRESULT WINAPI filecoll_enumvariant_Next(IEnumVARIANT *iface, ULONG celt,
WIN32_FIND_DATAW data;
ULONG count = 0;
- TRACE("(%p)->(%d %p %p)\n", This, celt, var, fetched);
+ TRACE("%p, %ld, %p, %p.\n", iface, celt, var, fetched);
if (fetched)
*fetched = 0;
@@ -1475,7 +1475,7 @@ static HRESULT WINAPI filecoll_enumvariant_Skip(IEnumVARIANT *iface, ULONG celt)
HANDLE handle = This->data.u.filecoll.find;
WIN32_FIND_DATAW data;
- TRACE("(%p)->(%d)\n", This, celt);
+ TRACE("%p, %lu.\n", iface, celt);
if (!celt) return S_OK;
@@ -1551,7 +1551,7 @@ static ULONG WINAPI drivecoll_enumvariant_Release(IEnumVARIANT *iface)
struct enumvariant *This = impl_from_IEnumVARIANT(iface);
ULONG ref = InterlockedDecrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
{
@@ -1581,7 +1581,7 @@ static HRESULT WINAPI drivecoll_enumvariant_Next(IEnumVARIANT *iface, ULONG celt
struct enumvariant *This = impl_from_IEnumVARIANT(iface);
ULONG count = 0;
- TRACE("(%p)->(%d %p %p)\n", This, celt, var, fetched);
+ TRACE("%p, %lu, %p, %p.\n", iface, celt, var, fetched);
if (fetched)
*fetched = 0;
@@ -1612,7 +1612,7 @@ static HRESULT WINAPI drivecoll_enumvariant_Skip(IEnumVARIANT *iface, ULONG celt
{
struct enumvariant *This = impl_from_IEnumVARIANT(iface);
- TRACE("(%p)->(%d)\n", This, celt);
+ TRACE("%p, %lu.\n", iface, celt);
if (!celt) return S_OK;
@@ -1696,22 +1696,25 @@ static HRESULT WINAPI foldercoll_QueryInterface(IFolderCollection *iface, REFIID
static ULONG WINAPI foldercoll_AddRef(IFolderCollection *iface)
{
- struct foldercollection *This = impl_from_IFolderCollection(iface);
- ULONG ref = InterlockedIncrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ struct foldercollection *collection = impl_from_IFolderCollection(iface);
+ ULONG ref = InterlockedIncrement(&collection->ref);
+
+ TRACE("%p, refcount %ld.\n", iface, ref);
+
return ref;
}
static ULONG WINAPI foldercoll_Release(IFolderCollection *iface)
{
- struct foldercollection *This = impl_from_IFolderCollection(iface);
- ULONG ref = InterlockedDecrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ struct foldercollection *collection = impl_from_IFolderCollection(iface);
+ ULONG ref = InterlockedDecrement(&collection->ref);
+
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
{
- SysFreeString(This->path);
- free(This);
+ SysFreeString(collection->path);
+ free(collection);
}
return ref;
@@ -1728,8 +1731,8 @@ static HRESULT WINAPI foldercoll_GetTypeInfoCount(IFolderCollection *iface, UINT
static HRESULT WINAPI foldercoll_GetTypeInfo(IFolderCollection *iface, UINT iTInfo,
LCID lcid, ITypeInfo **ppTInfo)
{
- struct foldercollection *This = impl_from_IFolderCollection(iface);
- TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
+
return get_typeinfo(IFolderCollection_tid, ppTInfo);
}
@@ -1737,11 +1740,10 @@ static HRESULT WINAPI foldercoll_GetIDsOfNames(IFolderCollection *iface, REFIID
LPOLESTR *rgszNames, UINT cNames,
LCID lcid, DISPID *rgDispId)
{
- struct foldercollection *This = impl_from_IFolderCollection(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IFolderCollection_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -1758,11 +1760,10 @@ static HRESULT WINAPI foldercoll_Invoke(IFolderCollection *iface, DISPID dispIdM
DISPPARAMS *pDispParams, VARIANT *pVarResult,
EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- struct foldercollection *This = impl_from_IFolderCollection(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IFolderCollection_tid, &typeinfo);
@@ -1897,22 +1898,25 @@ static HRESULT WINAPI filecoll_QueryInterface(IFileCollection *iface, REFIID rii
static ULONG WINAPI filecoll_AddRef(IFileCollection *iface)
{
- struct filecollection *This = impl_from_IFileCollection(iface);
- ULONG ref = InterlockedIncrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ struct filecollection *collection = impl_from_IFileCollection(iface);
+ ULONG ref = InterlockedIncrement(&collection->ref);
+
+ TRACE("%p, refcount %ld.\n", iface, ref);
+
return ref;
}
static ULONG WINAPI filecoll_Release(IFileCollection *iface)
{
- struct filecollection *This = impl_from_IFileCollection(iface);
- ULONG ref = InterlockedDecrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ struct filecollection *collection = impl_from_IFileCollection(iface);
+ ULONG ref = InterlockedDecrement(&collection->ref);
+
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
{
- SysFreeString(This->path);
- free(This);
+ SysFreeString(collection->path);
+ free(collection);
}
return ref;
@@ -1929,8 +1933,8 @@ static HRESULT WINAPI filecoll_GetTypeInfoCount(IFileCollection *iface, UINT *pc
static HRESULT WINAPI filecoll_GetTypeInfo(IFileCollection *iface, UINT iTInfo,
LCID lcid, ITypeInfo **ppTInfo)
{
- struct filecollection *This = impl_from_IFileCollection(iface);
- TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
+
return get_typeinfo(IFileCollection_tid, ppTInfo);
}
@@ -1938,11 +1942,10 @@ static HRESULT WINAPI filecoll_GetIDsOfNames(IFileCollection *iface, REFIID riid
LPOLESTR *rgszNames, UINT cNames,
LCID lcid, DISPID *rgDispId)
{
- struct filecollection *This = impl_from_IFileCollection(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IFileCollection_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -1959,11 +1962,10 @@ static HRESULT WINAPI filecoll_Invoke(IFileCollection *iface, DISPID dispIdMembe
DISPPARAMS *pDispParams, VARIANT *pVarResult,
EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- struct filecollection *This = impl_from_IFileCollection(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IFileCollection_tid, &typeinfo);
@@ -2089,20 +2091,23 @@ static HRESULT WINAPI drivecoll_QueryInterface(IDriveCollection *iface, REFIID r
static ULONG WINAPI drivecoll_AddRef(IDriveCollection *iface)
{
- struct drivecollection *This = impl_from_IDriveCollection(iface);
- ULONG ref = InterlockedIncrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ struct drivecollection *collection = impl_from_IDriveCollection(iface);
+ ULONG ref = InterlockedIncrement(&collection->ref);
+
+ TRACE("%p, refcount %ld.\n", iface, ref);
+
return ref;
}
static ULONG WINAPI drivecoll_Release(IDriveCollection *iface)
{
- struct drivecollection *This = impl_from_IDriveCollection(iface);
- ULONG ref = InterlockedDecrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ struct drivecollection *collection = impl_from_IDriveCollection(iface);
+ ULONG ref = InterlockedDecrement(&collection->ref);
+
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
- free(This);
+ free(collection);
return ref;
}
@@ -2118,8 +2123,8 @@ static HRESULT WINAPI drivecoll_GetTypeInfoCount(IDriveCollection *iface, UINT *
static HRESULT WINAPI drivecoll_GetTypeInfo(IDriveCollection *iface, UINT iTInfo,
LCID lcid, ITypeInfo **ppTInfo)
{
- struct drivecollection *This = impl_from_IDriveCollection(iface);
- TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
+
return get_typeinfo(IDriveCollection_tid, ppTInfo);
}
@@ -2127,11 +2132,10 @@ static HRESULT WINAPI drivecoll_GetIDsOfNames(IDriveCollection *iface, REFIID ri
LPOLESTR *rgszNames, UINT cNames,
LCID lcid, DISPID *rgDispId)
{
- struct drivecollection *This = impl_from_IDriveCollection(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IDriveCollection_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -2148,11 +2152,10 @@ static HRESULT WINAPI drivecoll_Invoke(IDriveCollection *iface, DISPID dispIdMem
DISPPARAMS *pDispParams, VARIANT *pVarResult,
EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- struct drivecollection *This = impl_from_IDriveCollection(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IDriveCollection_tid, &typeinfo);
@@ -2259,22 +2262,25 @@ static HRESULT WINAPI folder_QueryInterface(IFolder *iface, REFIID riid, void **
static ULONG WINAPI folder_AddRef(IFolder *iface)
{
- struct folder *This = impl_from_IFolder(iface);
- ULONG ref = InterlockedIncrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ struct folder *folder = impl_from_IFolder(iface);
+ ULONG ref = InterlockedIncrement(&folder->ref);
+
+ TRACE("%p, refcount %ld.\n", iface, ref);
+
return ref;
}
static ULONG WINAPI folder_Release(IFolder *iface)
{
- struct folder *This = impl_from_IFolder(iface);
- ULONG ref = InterlockedDecrement(&This->ref);
- TRACE("(%p)->(%d)\n", This, ref);
+ struct folder *folder = impl_from_IFolder(iface);
+ ULONG ref = InterlockedDecrement(&folder->ref);
+
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
{
- SysFreeString(This->path);
- free(This);
+ SysFreeString(folder->path);
+ free(folder);
}
return ref;
@@ -2291,8 +2297,8 @@ static HRESULT WINAPI folder_GetTypeInfoCount(IFolder *iface, UINT *pctinfo)
static HRESULT WINAPI folder_GetTypeInfo(IFolder *iface, UINT iTInfo,
LCID lcid, ITypeInfo **ppTInfo)
{
- struct folder *This = impl_from_IFolder(iface);
- TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
+
return get_typeinfo(IFolder_tid, ppTInfo);
}
@@ -2300,11 +2306,10 @@ static HRESULT WINAPI folder_GetIDsOfNames(IFolder *iface, REFIID riid,
LPOLESTR *rgszNames, UINT cNames,
LCID lcid, DISPID *rgDispId)
{
- struct folder *This = impl_from_IFolder(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IFolder_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -2321,11 +2326,10 @@ static HRESULT WINAPI folder_Invoke(IFolder *iface, DISPID dispIdMember,
DISPPARAMS *pDispParams, VARIANT *pVarResult,
EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- struct folder *This = impl_from_IFolder(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IFolder_tid, &typeinfo);
@@ -2617,10 +2621,10 @@ static HRESULT WINAPI file_QueryInterface(IFile *iface, REFIID riid, void **obj)
static ULONG WINAPI file_AddRef(IFile *iface)
{
- struct file *This = impl_from_IFile(iface);
- LONG ref = InterlockedIncrement(&This->ref);
+ struct file *file = impl_from_IFile(iface);
+ LONG ref = InterlockedIncrement(&file->ref);
- TRACE("(%p) ref=%d\n", This, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
return ref;
}
@@ -2630,7 +2634,7 @@ static ULONG WINAPI file_Release(IFile *iface)
struct file *file = impl_from_IFile(iface);
LONG ref = InterlockedDecrement(&file->ref);
- TRACE("%p, refcount %d.\n", iface, ref);
+ TRACE("%p, refcount %ld.\n", iface, ref);
if (!ref)
{
@@ -2654,9 +2658,7 @@ static HRESULT WINAPI file_GetTypeInfoCount(IFile *iface, UINT *pctinfo)
static HRESULT WINAPI file_GetTypeInfo(IFile *iface,
UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
{
- struct file *This = impl_from_IFile(iface);
-
- TRACE("(%p)->(%u %u %p)\n", This, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
return get_typeinfo(IFile_tid, ppTInfo);
}
@@ -2664,11 +2666,10 @@ static HRESULT WINAPI file_GetTypeInfo(IFile *iface,
static HRESULT WINAPI file_GetIDsOfNames(IFile *iface, REFIID riid,
LPOLESTR *rgszNames, UINT cNames, LCID lcid, DISPID *rgDispId)
{
- struct file *This = impl_from_IFile(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %u %u %p)\n", This, debugstr_guid(riid),
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid),
rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IFile_tid, &typeinfo);
@@ -2679,13 +2680,13 @@ static HRESULT WINAPI file_GetIDsOfNames(IFile *iface, REFIID riid,
return hr;
}
-static HRESULT WINAPI file_Invoke(IFile *iface, DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
+static HRESULT WINAPI file_Invoke(IFile *iface, DISPID dispIdMember, REFIID riid, LCID lcid, WORD wFlags,
+ DISPPARAMS *pDispParams, VARIANT *pVarResult, EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- struct file *This = impl_from_IFile(iface);
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IFile_tid, &typeinfo);
@@ -3046,7 +3047,8 @@ static HRESULT WINAPI filesys_GetTypeInfoCount(IFileSystem3 *iface, UINT *pctinf
static HRESULT WINAPI filesys_GetTypeInfo(IFileSystem3 *iface, UINT iTInfo,
LCID lcid, ITypeInfo **ppTInfo)
{
- TRACE("(%p)->(%u %u %p)\n", iface, iTInfo, lcid, ppTInfo);
+ TRACE("%p, %u, %lx, %p.\n", iface, iTInfo, lcid, ppTInfo);
+
return get_typeinfo(IFileSystem3_tid, ppTInfo);
}
@@ -3057,7 +3059,7 @@ static HRESULT WINAPI filesys_GetIDsOfNames(IFileSystem3 *iface, REFIID riid,
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %u %u %p)\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
+ TRACE("%p, %s, %p, %u, %lx, %p.\n", iface, debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
hr = get_typeinfo(IFileSystem3_tid, &typeinfo);
if(SUCCEEDED(hr))
@@ -3077,7 +3079,7 @@ static HRESULT WINAPI filesys_Invoke(IFileSystem3 *iface, DISPID dispIdMember,
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %d %p %p %p %p)\n", iface, dispIdMember, debugstr_guid(riid),
+ TRACE("%p, %ld, %s, %lx, %d, %p, %p, %p, %p.\n", iface, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IFileSystem3_tid, &typeinfo);
@@ -3939,7 +3941,7 @@ static HRESULT WINAPI filesys_GetFileVersion(IFileSystem3 *iface, BSTR name, BST
return HRESULT_FROM_WIN32(GetLastError());
}
- ret = VerQueryValueW(ptr, L"\\", (void **)&info, &len);
+ ret = VerQueryValueW(ptr, L"\\", (void **)&info, NULL);
if (!ret)
{
free(ptr);
diff --git a/dlls/scrrun/scrrun.c b/dlls/scrrun/scrrun.c
index 7f39d0e642a..117256d666b 100644
--- a/dlls/scrrun/scrrun.c
+++ b/dlls/scrrun/scrrun.c
@@ -126,7 +126,7 @@ static HRESULT load_typelib(void)
hres = LoadRegTypeLib(&LIBID_Scripting, 1, 0, LOCALE_SYSTEM_DEFAULT, &tl);
if(FAILED(hres)) {
- ERR("LoadRegTypeLib failed: %08x\n", hres);
+ ERR("LoadRegTypeLib failed: %#lx.\n", hres);
return hres;
}
@@ -157,7 +157,7 @@ HRESULT get_typeinfo(tid_t tid, ITypeInfo **typeinfo)
hres = ITypeLib_GetTypeInfoOfGuid(typelib, tid_ids[tid], &ti);
if(FAILED(hres)) {
- ERR("GetTypeInfoOfGuid(%s) failed: %08x\n", debugstr_guid(tid_ids[tid]), hres);
+ ERR("GetTypeInfoOfGuid(%s) failed: %#lx.\n", debugstr_guid(tid_ids[tid]), hres);
return hres;
}
@@ -236,7 +236,7 @@ void init_classinfo(const GUID *guid, IUnknown *outer, struct provideclassinfo *
BOOL WINAPI DllMain( HINSTANCE hinst, DWORD reason, LPVOID reserved )
{
- TRACE("%p, %u, %p\n", hinst, reason, reserved);
+ TRACE("%p, %lu, %p\n", hinst, reason, reserved);
switch (reason)
{
--
2.34.1
1
0
Signed-off-by: Hans Leidekker <hans(a)codeweavers.com>
---
dlls/wbemdisp/locator.c | 62 +++++++++++++++++++----------------------
dlls/wbemdisp/main.c | 1 -
2 files changed, 29 insertions(+), 34 deletions(-)
diff --git a/dlls/wbemdisp/locator.c b/dlls/wbemdisp/locator.c
index 3e2566d5220..ffd6debec4d 100644
--- a/dlls/wbemdisp/locator.c
+++ b/dlls/wbemdisp/locator.c
@@ -29,7 +29,6 @@
#include "wbemdisp.h"
#include "wine/debug.h"
-#include "wine/heap.h"
#include "wbemdisp_private.h"
#include "wbemdisp_classes.h"
@@ -55,7 +54,7 @@ static WCHAR *heap_strdupW( const WCHAR *src )
{
WCHAR *dst;
if (!src) return NULL;
- if ((dst = heap_alloc( (lstrlenW( src ) + 1) * sizeof(WCHAR) ))) lstrcpyW( dst, src );
+ if ((dst = malloc( (lstrlenW( src ) + 1) * sizeof(WCHAR) ))) lstrcpyW( dst, src );
return dst;
}
@@ -162,7 +161,7 @@ static ULONG WINAPI property_Release( ISWbemProperty *iface )
TRACE( "destroying %p\n", property );
IWbemClassObject_Release( property->object );
SysFreeString( property->name );
- heap_free( property );
+ free( property );
}
return refs;
}
@@ -322,7 +321,7 @@ static HRESULT SWbemProperty_create( IWbemClassObject *wbem_object, BSTR name, I
TRACE( "%p, %p\n", obj, wbem_object );
- if (!(property = heap_alloc( sizeof(*property) ))) return E_OUTOFMEMORY;
+ if (!(property = malloc( sizeof(*property) ))) return E_OUTOFMEMORY;
property->ISWbemProperty_iface.lpVtbl = &property_vtbl;
property->refs = 1;
property->object = wbem_object;
@@ -360,7 +359,7 @@ static ULONG WINAPI propertyset_Release( ISWbemPropertySet *iface )
{
TRACE( "destroying %p\n", propertyset );
IWbemClassObject_Release( propertyset->object );
- heap_free( propertyset );
+ free( propertyset );
}
return refs;
}
@@ -520,7 +519,7 @@ static HRESULT SWbemPropertySet_create( IWbemClassObject *wbem_object, ISWbemPro
TRACE( "%p, %p\n", obj, wbem_object );
- if (!(propertyset = heap_alloc( sizeof(*propertyset) ))) return E_OUTOFMEMORY;
+ if (!(propertyset = malloc( sizeof(*propertyset) ))) return E_OUTOFMEMORY;
propertyset->ISWbemPropertySet_iface.lpVtbl = &propertyset_vtbl;
propertyset->refs = 1;
propertyset->object = wbem_object;
@@ -613,8 +612,8 @@ static ULONG WINAPI method_Release( ISWbemMethod *iface )
{
TRACE( "destroying %p\n", method );
ISWbemMethodSet_Release( &method->set->ISWbemMethodSet_iface );
- heap_free( method->name );
- heap_free( method );
+ free( method->name );
+ free( method );
}
return refs;
}
@@ -779,8 +778,7 @@ static HRESULT SWbemMethod_create( struct methodset *set, const WCHAR *name, ISW
{
struct method *method;
- if (!(method = heap_alloc(sizeof(*method))))
- return E_OUTOFMEMORY;
+ if (!(method = malloc( sizeof(*method) ))) return E_OUTOFMEMORY;
method->ISWbemMethod_iface.lpVtbl = &methodvtbl;
method->refs = 1;
@@ -837,7 +835,7 @@ static ULONG WINAPI methodset_Release( ISWbemMethodSet *iface )
{
TRACE( "destroying %p\n", set );
ISWbemObject_Release( &set->object->ISWbemObject_iface );
- heap_free( set );
+ free( set );
}
return refs;
}
@@ -982,8 +980,7 @@ static HRESULT SWbemMethodSet_create( struct object *object, ISWbemMethodSet **o
{
struct methodset *set;
- if (!(set = heap_alloc(sizeof(*set))))
- return E_OUTOFMEMORY;
+ if (!(set = malloc( sizeof(*set) ))) return E_OUTOFMEMORY;
set->ISWbemMethodSet_iface.lpVtbl = &methodsetvtbl;
set->refs = 1;
@@ -1024,8 +1021,8 @@ static ULONG WINAPI object_Release(
IWbemClassObject_Release( object->object );
ISWbemServices_Release( &object->services->ISWbemServices_iface );
for (i = 0; i < object->nb_members; i++) SysFreeString( object->members[i].name );
- heap_free( object->members );
- heap_free( object );
+ free( object->members );
+ free( object );
}
return refs;
}
@@ -1094,7 +1091,7 @@ static BOOL object_reserve_member( struct object *object, unsigned int count, un
if (new_capacity < count)
new_capacity = max_capacity;
- if (!(new_members = heap_realloc( object->members, new_capacity * sizeof(*new_members) )))
+ if (!(new_members = realloc( object->members, new_capacity * sizeof(*new_members) )))
return FALSE;
object->members = new_members;
@@ -1153,7 +1150,7 @@ static HRESULT init_members( struct object *object )
error:
for (i = 0; i < count; ++i)
SysFreeString( object->members[i].name );
- heap_free( object->members );
+ free( object->members );
object->members = NULL;
object->nb_members = 0;
return E_FAIL;
@@ -1677,7 +1674,7 @@ static HRESULT SWbemObject_create( struct services *services, IWbemClassObject *
TRACE( "%p, %p\n", obj, wbem_object );
- if (!(object = heap_alloc( sizeof(*object) ))) return E_OUTOFMEMORY;
+ if (!(object = malloc( sizeof(*object) ))) return E_OUTOFMEMORY;
object->ISWbemObject_iface.lpVtbl = &object_vtbl;
object->refs = 1;
object->object = wbem_object;
@@ -1726,7 +1723,7 @@ static ULONG WINAPI objectset_Release(
TRACE( "destroying %p\n", objectset );
IEnumWbemClassObject_Release( objectset->objectenum );
ISWbemServices_Release( &objectset->services->ISWbemServices_iface );
- heap_free( objectset );
+ free( objectset );
}
return refs;
}
@@ -1949,7 +1946,7 @@ static HRESULT SWbemObjectSet_create( struct services *services, IEnumWbemClassO
TRACE( "%p, %p\n", obj, wbem_objectenum );
- if (!(objectset = heap_alloc( sizeof(*objectset) ))) return E_OUTOFMEMORY;
+ if (!(objectset = malloc( sizeof(*objectset) ))) return E_OUTOFMEMORY;
objectset->ISWbemObjectSet_iface.lpVtbl = &objectset_vtbl;
objectset->refs = 1;
objectset->objectenum = wbem_objectenum;
@@ -1994,7 +1991,7 @@ static ULONG WINAPI enumvar_Release(
TRACE( "destroying %p\n", enumvar );
IEnumWbemClassObject_Release( enumvar->objectenum );
ISWbemServices_Release( &enumvar->services->ISWbemServices_iface );
- heap_free( enumvar );
+ free( enumvar );
}
return refs;
}
@@ -2087,7 +2084,7 @@ static HRESULT EnumVARIANT_create( struct services *services, IEnumWbemClassObje
{
struct enumvar *enumvar;
- if (!(enumvar = heap_alloc( sizeof(*enumvar) ))) return E_OUTOFMEMORY;
+ if (!(enumvar = malloc( sizeof(*enumvar) ))) return E_OUTOFMEMORY;
enumvar->IEnumVARIANT_iface.lpVtbl = &enumvar_vtbl;
enumvar->refs = 1;
enumvar->objectenum = objectenum;
@@ -2122,7 +2119,7 @@ static ULONG WINAPI services_Release(
{
TRACE( "destroying %p\n", services );
IWbemServices_Release( services->services );
- heap_free( services );
+ free( services );
}
return refs;
}
@@ -2587,7 +2584,7 @@ static HRESULT SWbemServices_create( IWbemServices *wbem_services, ISWbemService
TRACE( "%p, %p\n", obj, wbem_services );
- if (!(services = heap_alloc( sizeof(*services) ))) return E_OUTOFMEMORY;
+ if (!(services = malloc( sizeof(*services) ))) return E_OUTOFMEMORY;
services->ISWbemServices_iface.lpVtbl = &services_vtbl;
services->refs = 1;
services->services = wbem_services;
@@ -2627,7 +2624,7 @@ static ULONG WINAPI locator_Release(
TRACE( "destroying %p\n", locator );
if (locator->locator)
IWbemLocator_Release( locator->locator );
- heap_free( locator );
+ free( locator );
}
return refs;
}
@@ -2829,7 +2826,7 @@ HRESULT SWbemLocator_create( void **obj )
TRACE( "%p\n", obj );
- if (!(locator = heap_alloc( sizeof(*locator) ))) return E_OUTOFMEMORY;
+ if (!(locator = malloc( sizeof(*locator) ))) return E_OUTOFMEMORY;
locator->ISWbemLocator_iface.lpVtbl = &locator_vtbl;
locator->refs = 1;
locator->locator = NULL;
@@ -2867,7 +2864,7 @@ static ULONG WINAPI security_Release(
if (!refs)
{
TRACE( "destroying %p\n", security );
- heap_free( security );
+ free( security );
}
return refs;
}
@@ -3056,7 +3053,7 @@ static HRESULT ISWbemSecurity_create( ISWbemSecurity **obj )
TRACE( "%p\n", obj );
- if (!(security = heap_alloc( sizeof(*security) ))) return E_OUTOFMEMORY;
+ if (!(security = malloc( sizeof(*security) ))) return E_OUTOFMEMORY;
security->ISWbemSecurity_iface.lpVtbl = &security_vtbl;
security->refs = 1;
security->implevel = wbemImpersonationLevelImpersonate;
@@ -3122,7 +3119,7 @@ static ULONG WINAPI namedvalue_Release(
if (!refs)
{
TRACE( "destroying %p\n", value );
- heap_free( value );
+ free( value );
}
return refs;
}
@@ -3249,8 +3246,7 @@ static HRESULT namedvalue_create( ISWbemNamedValue **value )
{
struct namedvalue *object;
- if (!(object = heap_alloc(sizeof(*object))))
- return E_OUTOFMEMORY;
+ if (!(object = malloc( sizeof(*object) ))) return E_OUTOFMEMORY;
object->ISWbemNamedValue_iface.lpVtbl = &namedvaluevtbl;
object->refs = 1;
@@ -3301,7 +3297,7 @@ static ULONG WINAPI namedvalueset_Release(
TRACE( "destroying %p\n", set );
if (set->context)
IWbemContext_Release( set->context );
- heap_free( set );
+ free( set );
}
return refs;
}
@@ -3513,7 +3509,7 @@ HRESULT SWbemNamedValueSet_create( void **obj )
TRACE( "%p\n", obj );
- if (!(set = heap_alloc_zero( sizeof(*set) ))) return E_OUTOFMEMORY;
+ if (!(set = calloc( 1, sizeof(*set) ))) return E_OUTOFMEMORY;
set->ISWbemNamedValueSet_iface.lpVtbl = &namedvalueset_vtbl;
set->refs = 1;
diff --git a/dlls/wbemdisp/main.c b/dlls/wbemdisp/main.c
index 0ceb417ad52..b71efdb6da0 100644
--- a/dlls/wbemdisp/main.c
+++ b/dlls/wbemdisp/main.c
@@ -28,7 +28,6 @@
#include "rpcproxy.h"
#include "wine/debug.h"
-#include "wine/heap.h"
#include "wbemdisp_private.h"
#include "wbemdisp_classes.h"
--
2.30.2
1
0