Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
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-winehq
Commits
01c28255
Commit
01c28255
authored
Apr 18, 2013
by
Alistair Leslie-Hughes
Committed by
Alexandre Julliard
Apr 22, 2013
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
oledb32: Implement DataConvert DBTYPE_I8->DBTYPE_VARIANT.
parent
dd104f67
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
0 deletions
+18
-0
convert.c
dlls/oledb32/convert.c
+4
-0
convert.c
dlls/oledb32/tests/convert.c
+14
-0
No files found.
dlls/oledb32/convert.c
View file @
01c28255
...
...
@@ -757,6 +757,10 @@ static HRESULT WINAPI convert_DataConvert(IDataConvert* iface,
V_I4
(
v
)
=
*
(
signed
int
*
)
src
;
hr
=
S_OK
;
break
;
case
DBTYPE_I8
:
V_VT
(
v
)
=
VT_DECIMAL
;
hr
=
VarDecFromI8
(
*
(
LONGLONG
*
)
src
,
&
V_DECIMAL
(
v
));
break
;
case
DBTYPE_BSTR
:
{
BSTR
s
=
*
(
WCHAR
**
)
src
;
...
...
dlls/oledb32/tests/convert.c
View file @
01c28255
...
...
@@ -2544,6 +2544,7 @@ static void test_converttovar(void)
CY
cy
,
cy2
;
DATE
date
;
INT
i4
;
LARGE_INTEGER
i8
;
hr
=
CoCreateInstance
(
&
CLSID_OLEDB_CONVERSIONLIBRARY
,
NULL
,
CLSCTX_INPROC_SERVER
,
&
IID_IDataConvert
,
(
void
**
)
&
convert
);
if
(
FAILED
(
hr
))
...
...
@@ -2574,6 +2575,19 @@ static void test_converttovar(void)
V_VT
(
&
dst
)
=
VT_EMPTY
;
dst_len
=
0
;
dst_status
=
DBSTATUS_S_DEFAULT
;
i8
.
QuadPart
=
12345
;
dst_len
=
0x1234
;
hr
=
IDataConvert_DataConvert
(
convert
,
DBTYPE_I8
,
DBTYPE_VARIANT
,
sizeof
(
i8
),
&
dst_len
,
&
i8
,
&
dst
,
sizeof
(
dst
),
0
,
&
dst_status
,
0
,
0
,
0
);
ok
(
hr
==
S_OK
,
"got %08x
\n
"
,
hr
);
ok
(
dst_status
==
DBSTATUS_S_OK
,
"got %08x
\n
"
,
dst_status
);
ok
(
dst_len
==
sizeof
(
dst
),
"got %ld
\n
"
,
dst_len
);
ok
(
V_VT
(
&
dst
)
==
VT_DECIMAL
,
"got %d
\n
"
,
V_VT
(
&
dst
));
ok
(
S
(
U
(
V_DECIMAL
(
&
dst
))).
scale
==
0
&&
S
(
U
(
V_DECIMAL
(
&
dst
))).
sign
==
0
&&
V_DECIMAL
(
&
dst
).
Hi32
==
0
&&
U1
(
V_DECIMAL
(
&
dst
)).
Lo64
==
12345
,
"Not Equal
\n
"
);
V_VT
(
&
dst
)
=
VT_EMPTY
;
dst_len
=
0
;
dst_status
=
DBSTATUS_S_DEFAULT
;
i4
=
123
;
hr
=
IDataConvert_DataConvert
(
convert
,
DBTYPE_I4
,
DBTYPE_VARIANT
,
sizeof
(
i4
),
&
dst_len
,
&
i4
,
&
dst
,
sizeof
(
dst
),
0
,
&
dst_status
,
0
,
0
,
0
);
ok
(
hr
==
S_OK
,
"got %08x
\n
"
,
hr
);
...
...
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