Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-cw
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-cw
Commits
18a42e02
Commit
18a42e02
authored
May 23, 2014
by
Jacek Caban
Committed by
Alexandre Julliard
May 24, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
oleaut32: Use debugstr_variant for dump_Variant implementation.
parent
5614770c
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
34 additions
and
53 deletions
+34
-53
typelib.c
dlls/oleaut32/typelib.c
+1
-51
variant.c
dlls/oleaut32/variant.c
+33
-2
No files found.
dlls/oleaut32/typelib.c
View file @
18a42e02
...
...
@@ -1539,57 +1539,7 @@ static void dump_TLBImplType(const TLBImplType * impl, UINT n)
static
void
dump_Variant
(
const
VARIANT
*
pvar
)
{
SYSTEMTIME
st
;
TRACE
(
"%p->{%s"
,
pvar
,
debugstr_vt
(
V_VT
(
pvar
)));
if
(
pvar
)
{
if
(
V_ISBYREF
(
pvar
)
||
V_TYPE
(
pvar
)
==
VT_UNKNOWN
||
V_TYPE
(
pvar
)
==
VT_DISPATCH
||
V_TYPE
(
pvar
)
==
VT_RECORD
)
{
TRACE
(
",%p"
,
V_BYREF
(
pvar
));
}
else
if
(
V_ISARRAY
(
pvar
)
||
V_ISVECTOR
(
pvar
))
{
TRACE
(
",%p"
,
V_ARRAY
(
pvar
));
}
else
switch
(
V_TYPE
(
pvar
))
{
case
VT_I1
:
TRACE
(
",%d"
,
V_I1
(
pvar
));
break
;
case
VT_UI1
:
TRACE
(
",%d"
,
V_UI1
(
pvar
));
break
;
case
VT_I2
:
TRACE
(
",%d"
,
V_I2
(
pvar
));
break
;
case
VT_UI2
:
TRACE
(
",%d"
,
V_UI2
(
pvar
));
break
;
case
VT_INT
:
case
VT_I4
:
TRACE
(
",%d"
,
V_I4
(
pvar
));
break
;
case
VT_UINT
:
case
VT_UI4
:
TRACE
(
",%d"
,
V_UI4
(
pvar
));
break
;
case
VT_I8
:
TRACE
(
",0x%08x,0x%08x"
,
(
ULONG
)(
V_I8
(
pvar
)
>>
32
),
(
ULONG
)(
V_I8
(
pvar
)
&
0xffffffff
));
break
;
case
VT_UI8
:
TRACE
(
",0x%08x,0x%08x"
,
(
ULONG
)(
V_UI8
(
pvar
)
>>
32
),
(
ULONG
)(
V_UI8
(
pvar
)
&
0xffffffff
));
break
;
case
VT_R4
:
TRACE
(
",%3.3e"
,
V_R4
(
pvar
));
break
;
case
VT_R8
:
TRACE
(
",%3.3e"
,
V_R8
(
pvar
));
break
;
case
VT_BOOL
:
TRACE
(
",%s"
,
V_BOOL
(
pvar
)
?
"TRUE"
:
"FALSE"
);
break
;
case
VT_BSTR
:
TRACE
(
",%s"
,
debugstr_w
(
V_BSTR
(
pvar
)));
break
;
case
VT_CY
:
TRACE
(
",0x%08x,0x%08x"
,
V_CY
(
pvar
).
s
.
Hi
,
V_CY
(
pvar
).
s
.
Lo
);
break
;
case
VT_DATE
:
if
(
!
VariantTimeToSystemTime
(
V_DATE
(
pvar
),
&
st
))
TRACE
(
",<invalid>"
);
else
TRACE
(
",%04d/%02d/%02d %02d:%02d:%02d"
,
st
.
wYear
,
st
.
wMonth
,
st
.
wDay
,
st
.
wHour
,
st
.
wMinute
,
st
.
wSecond
);
break
;
case
VT_ERROR
:
case
VT_VOID
:
case
VT_USERDEFINED
:
case
VT_EMPTY
:
case
VT_NULL
:
break
;
default:
TRACE
(
",?"
);
break
;
}
}
TRACE
(
"}
\n
"
);
TRACE
(
"%s
\n
"
,
debugstr_variant
(
pvar
));
}
static
void
dump_DispParms
(
const
DISPPARAMS
*
pdp
)
...
...
dlls/oleaut32/variant.c
View file @
18a42e02
...
...
@@ -98,13 +98,20 @@ const char *debugstr_variant(const VARIANT *v)
if
(
!
v
)
return
"(null)"
;
if
(
V_VT
(
v
)
&
VT_BYREF
)
{
if
(
V_VT
(
v
)
==
(
VT_VARIANT
|
VT_BYREF
))
return
wine_dbg_sprintf
(
"%p {VT_VARIANT|VT_BYREF: %s}"
,
v
,
debugstr_variant
(
V_VARIANTREF
(
v
)));
return
wine_dbg_sprintf
(
"%p {%s %p}"
,
v
,
debugstr_vt
(
V_VT
(
v
)),
V_BYREF
(
v
));
}
if
(
V_ISARRAY
(
v
)
||
V_ISVECTOR
(
v
))
return
wine_dbg_sprintf
(
"%p {%s %p}"
,
v
,
debugstr_vt
(
V_VT
(
v
)),
V_ARRAY
(
v
));
switch
(
V_VT
(
v
))
{
case
VT_EMPTY
:
return
wine_dbg_sprintf
(
"%p {VT_EMPTY}"
,
v
);
case
VT_NULL
:
return
wine_dbg_sprintf
(
"%p {VT_NULL}"
,
v
);
case
VT_I1
:
return
wine_dbg_sprintf
(
"%p {VT_I1: %d}"
,
v
,
V_I1
(
v
));
case
VT_I2
:
return
wine_dbg_sprintf
(
"%p {VT_I2: %d}"
,
v
,
V_I2
(
v
));
case
VT_I4
:
...
...
@@ -113,6 +120,10 @@ const char *debugstr_variant(const VARIANT *v)
return
wine_dbg_sprintf
(
"%p {VT_R4: %f}"
,
v
,
V_R4
(
v
));
case
VT_R8
:
return
wine_dbg_sprintf
(
"%p {VT_R8: %lf}"
,
v
,
V_R8
(
v
));
case
VT_CY
:
return
wine_dbg_sprintf
(
"%p {VT_CY: %s}"
,
v
,
wine_dbgstr_longlong
(
V_CY
(
v
).
int64
));
case
VT_DATE
:
return
wine_dbg_sprintf
(
"%p {VT_DATE: %lf}"
,
v
,
V_DATE
(
v
));
case
VT_BSTR
:
return
wine_dbg_sprintf
(
"%p {VT_BSTR: %s}"
,
v
,
debugstr_w
(
V_BSTR
(
v
)));
case
VT_DISPATCH
:
...
...
@@ -121,8 +132,28 @@ const char *debugstr_variant(const VARIANT *v)
return
wine_dbg_sprintf
(
"%p {VT_ERROR: %08x}"
,
v
,
V_ERROR
(
v
));
case
VT_BOOL
:
return
wine_dbg_sprintf
(
"%p {VT_BOOL: %x}"
,
v
,
V_BOOL
(
v
));
case
VT_UNKNOWN
:
return
wine_dbg_sprintf
(
"%p {VT_UNKNOWN: %p}"
,
v
,
V_UNKNOWN
(
v
));
case
VT_I1
:
return
wine_dbg_sprintf
(
"%p {VT_I1: %d}"
,
v
,
V_I1
(
v
));
case
VT_UI1
:
return
wine_dbg_sprintf
(
"%p {VT_UI1: %u}"
,
v
,
V_UI1
(
v
));
case
VT_UI2
:
return
wine_dbg_sprintf
(
"%p {VT_UI2: %d}"
,
v
,
V_UI2
(
v
));
case
VT_UI4
:
return
wine_dbg_sprintf
(
"%p {VT_UI4: %d}"
,
v
,
V_UI4
(
v
));
case
VT_I8
:
return
wine_dbg_sprintf
(
"%p {VT_I8: %s}"
,
v
,
wine_dbgstr_longlong
(
V_I8
(
v
)));
case
VT_UI8
:
return
wine_dbg_sprintf
(
"%p {VT_UI8: %s}"
,
v
,
wine_dbgstr_longlong
(
V_UI8
(
v
)));
case
VT_INT
:
return
wine_dbg_sprintf
(
"%p {VT_INT: %d}"
,
v
,
V_INT
(
v
));
case
VT_UINT
:
return
wine_dbg_sprintf
(
"%p {VT_UINT: %u}"
,
v
,
V_UINT
(
v
));
case
VT_VOID
:
return
wine_dbg_sprintf
(
"%p {VT_VOID}"
,
v
);
case
VT_RECORD
:
return
wine_dbg_sprintf
(
"%p {VT_RECORD: %p %p}"
,
v
,
V_UNION
(
v
,
brecVal
).
pvRecord
,
V_UNION
(
v
,
brecVal
).
pRecInfo
);
default:
return
wine_dbg_sprintf
(
"%p {vt %s}"
,
v
,
debugstr_vt
(
V_VT
(
v
)));
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment