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
a5939587
Commit
a5939587
authored
Dec 11, 2019
by
Hans Leidekker
Committed by
Alexandre Julliard
Dec 11, 2019
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msado15: Implement Fields_get_Count.
Signed-off-by:
Hans Leidekker
<
hans@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
0e897cb5
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
52 additions
and
4 deletions
+52
-4
recordset.c
dlls/msado15/recordset.c
+6
-2
msado15.c
dlls/msado15/tests/msado15.c
+46
-2
No files found.
dlls/msado15/recordset.c
View file @
a5939587
...
...
@@ -388,8 +388,12 @@ static HRESULT WINAPI fields_Invoke( Fields *iface, DISPID member, REFIID riid,
static
HRESULT
WINAPI
fields_get_Count
(
Fields
*
iface
,
LONG
*
count
)
{
FIXME
(
"%p, %p
\n
"
,
iface
,
count
);
return
E_NOTIMPL
;
struct
fields
*
fields
=
impl_from_Fields
(
iface
);
TRACE
(
"%p, %p
\n
"
,
fields
,
count
);
*
count
=
fields
->
count
;
return
S_OK
;
}
static
HRESULT
WINAPI
fields__NewEnum
(
Fields
*
iface
,
IUnknown
**
obj
)
...
...
dlls/msado15/tests/msado15.c
View file @
a5939587
...
...
@@ -77,8 +77,8 @@ static void test_Recordset(void)
count
=
-
1
;
hr
=
Fields_get_Count
(
fields2
,
&
count
);
todo_wine
ok
(
hr
==
S_OK
,
"got %08x
\n
"
,
hr
);
todo_wine
ok
(
!
count
,
"got %d
\n
"
,
count
);
ok
(
hr
==
S_OK
,
"got %08x
\n
"
,
hr
);
ok
(
!
count
,
"got %d
\n
"
,
count
);
refs
=
_Recordset_Release
(
recordset
);
ok
(
!
refs
,
"got %d
\n
"
,
refs
);
...
...
@@ -88,6 +88,49 @@ static void test_Recordset(void)
ok
(
refs
==
1
,
"got %d
\n
"
,
refs
);
}
static
void
test_Fields
(
void
)
{
_Recordset
*
recordset
;
Fields
*
fields
;
VARIANT
val
;
BSTR
name
;
LONG
count
;
HRESULT
hr
;
hr
=
CoCreateInstance
(
&
CLSID_Recordset
,
NULL
,
CLSCTX_INPROC_SERVER
,
&
IID__Recordset
,
(
void
**
)
&
recordset
);
ok
(
hr
==
S_OK
,
"got %08x
\n
"
,
hr
);
hr
=
_Recordset_get_Fields
(
recordset
,
&
fields
);
ok
(
hr
==
S_OK
,
"got %08x
\n
"
,
hr
);
count
=
-
1
;
hr
=
Fields_get_Count
(
fields
,
&
count
);
ok
(
!
count
,
"got %d
\n
"
,
count
);
name
=
SysAllocString
(
L"field"
);
V_VT
(
&
val
)
=
VT_ERROR
;
V_ERROR
(
&
val
)
=
DISP_E_PARAMNOTFOUND
;
hr
=
Fields_Append
(
fields
,
name
,
adInteger
,
4
,
adFldUnspecified
,
val
);
ok
(
hr
==
S_OK
,
"got %08x
\n
"
,
hr
);
SysFreeString
(
name
);
count
=
-
1
;
hr
=
Fields_get_Count
(
fields
,
&
count
);
ok
(
count
==
1
,
"got %d
\n
"
,
count
);
name
=
SysAllocString
(
L"field2"
);
hr
=
Fields__Append
(
fields
,
name
,
adInteger
,
4
,
adFldUnspecified
);
ok
(
hr
==
S_OK
,
"got %08x
\n
"
,
hr
);
SysFreeString
(
name
);
count
=
-
1
;
hr
=
Fields_get_Count
(
fields
,
&
count
);
ok
(
count
==
2
,
"got %d
\n
"
,
count
);
Fields_Release
(
fields
);
_Recordset_Release
(
recordset
);
}
static
HRESULT
str_to_byte_array
(
const
char
*
data
,
VARIANT
*
ret
)
{
SAFEARRAY
*
vector
;
...
...
@@ -406,6 +449,7 @@ START_TEST(msado15)
{
CoInitialize
(
NULL
);
test_Connection
();
test_Fields
();
test_Recordset
();
test_Stream
();
CoUninitialize
();
...
...
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