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
c8175e6c
Commit
c8175e6c
authored
Sep 03, 2018
by
Nikolay Sivov
Committed by
Alexandre Julliard
Sep 03, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shlwapi: Fix Stat() method for file streams.
Signed-off-by:
Nikolay Sivov
<
nsivov@codeweavers.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
53271d95
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
1 deletion
+13
-1
istream.c
dlls/shlwapi/istream.c
+1
-1
istream.c
dlls/shlwapi/tests/istream.c
+12
-0
No files found.
dlls/shlwapi/istream.c
View file @
c8175e6c
...
...
@@ -306,7 +306,7 @@ static HRESULT WINAPI IStream_fnStat(IStream *iface, STATSTG* lpStat,
TRACE
(
"(%p,%p,%d)
\n
"
,
This
,
lpStat
,
grfStatFlag
);
if
(
!
grfStatFlag
)
if
(
!
lpStat
)
return
STG_E_INVALIDPOINTER
;
memset
(
&
fi
,
0
,
sizeof
(
fi
));
...
...
dlls/shlwapi/tests/istream.c
View file @
c8175e6c
...
...
@@ -191,6 +191,7 @@ static void test_stream_read_write(IStream *stream, DWORD mode)
HRESULT
ret
;
unsigned
char
buf
[
16
];
DWORD
written
,
count
;
STATSTG
statstg
;
/* IStream_Read/Write from the COBJMACROS is undefined by shlwapi.h */
...
...
@@ -245,6 +246,17 @@ static void test_stream_read_write(IStream *stream, DWORD mode)
ok
(
count
==
written
,
"expected %u, got %u
\n
"
,
written
,
count
);
if
(
count
)
ok
(
buf
[
0
]
==
0x5e
&&
buf
[
1
]
==
0xa7
,
"expected 5ea7, got %02x%02x
\n
"
,
buf
[
0
],
buf
[
1
]);
memset
(
&
statstg
,
0xff
,
sizeof
(
statstg
));
ret
=
IStream_Stat
(
stream
,
&
statstg
,
0
);
ok
(
ret
==
S_OK
,
"Stat failed, hr %#x.
\n
"
,
ret
);
ok
(
statstg
.
pwcsName
!=
NULL
,
"Unexpected name %s.
\n
"
,
wine_dbgstr_w
(
statstg
.
pwcsName
));
CoTaskMemFree
(
statstg
.
pwcsName
);
memset
(
&
statstg
,
0xff
,
sizeof
(
statstg
));
ret
=
IStream_Stat
(
stream
,
&
statstg
,
STATFLAG_NONAME
);
ok
(
ret
==
S_OK
,
"Stat failed, hr %#x.
\n
"
,
ret
);
ok
(
statstg
.
pwcsName
==
NULL
,
"Unexpected name %s.
\n
"
,
wine_dbgstr_w
(
statstg
.
pwcsName
));
}
static
void
test_stream_qi
(
IStream
*
stream
)
...
...
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