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
7865b1a2
Commit
7865b1a2
authored
Jul 19, 2014
by
Thomas Faber
Committed by
Alexandre Julliard
Jul 21, 2014
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel32: Do not omit mandatory argument to DeviceIoControl.
parent
21a7cc6f
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
4 deletions
+8
-4
volume.c
dlls/kernel32/volume.c
+8
-4
No files found.
dlls/kernel32/volume.c
View file @
7865b1a2
...
...
@@ -187,6 +187,7 @@ static DWORD get_mountmgr_drive_type( LPCWSTR root )
{
HANDLE
mgr
;
struct
mountmgr_unix_drive
data
;
DWORD
br
;
memset
(
&
data
,
0
,
sizeof
(
data
)
);
if
(
root
)
data
.
letter
=
root
[
0
];
...
...
@@ -203,7 +204,7 @@ static DWORD get_mountmgr_drive_type( LPCWSTR root )
if
(
mgr
==
INVALID_HANDLE_VALUE
)
return
DRIVE_UNKNOWN
;
if
(
!
DeviceIoControl
(
mgr
,
IOCTL_MOUNTMGR_QUERY_UNIX_DRIVE
,
&
data
,
sizeof
(
data
),
&
data
,
sizeof
(
data
),
NULL
,
NULL
)
&&
GetLastError
()
!=
ERROR_MORE_DATA
)
sizeof
(
data
),
&
br
,
NULL
)
&&
GetLastError
()
!=
ERROR_MORE_DATA
)
data
.
type
=
DRIVE_UNKNOWN
;
CloseHandle
(
mgr
);
...
...
@@ -1044,6 +1045,7 @@ BOOL WINAPI GetVolumeNameForVolumeMountPointW( LPCWSTR path, LPWSTR volume, DWOR
NTSTATUS
status
;
HANDLE
mgr
=
INVALID_HANDLE_VALUE
;
BOOL
ret
=
FALSE
;
DWORD
br
;
TRACE
(
"(%s, %p, %x)
\n
"
,
debugstr_w
(
path
),
volume
,
size
);
if
(
path
[
lstrlenW
(
path
)
-
1
]
!=
'\\'
)
...
...
@@ -1110,7 +1112,7 @@ BOOL WINAPI GetVolumeNameForVolumeMountPointW( LPCWSTR path, LPWSTR volume, DWOR
/* now get the true volume name from the mountmgr */
if
(
!
DeviceIoControl
(
mgr
,
IOCTL_MOUNTMGR_QUERY_POINTS
,
input
,
i_size
,
output
,
o_size
,
NULL
,
NULL
))
output
,
o_size
,
&
br
,
NULL
))
goto
err_ret
;
/* Verify and return the data, note string is not null terminated */
...
...
@@ -1869,6 +1871,7 @@ static MOUNTMGR_MOUNT_POINTS *query_mount_points( HANDLE mgr, MOUNTMGR_MOUNT_POI
{
MOUNTMGR_MOUNT_POINTS
*
output
;
DWORD
outsize
=
1024
;
DWORD
br
;
for
(;;)
{
...
...
@@ -1877,7 +1880,7 @@ static MOUNTMGR_MOUNT_POINTS *query_mount_points( HANDLE mgr, MOUNTMGR_MOUNT_POI
SetLastError
(
ERROR_NOT_ENOUGH_MEMORY
);
return
NULL
;
}
if
(
DeviceIoControl
(
mgr
,
IOCTL_MOUNTMGR_QUERY_POINTS
,
input
,
insize
,
output
,
outsize
,
NULL
,
NULL
))
break
;
if
(
DeviceIoControl
(
mgr
,
IOCTL_MOUNTMGR_QUERY_POINTS
,
input
,
insize
,
output
,
outsize
,
&
br
,
NULL
))
break
;
outsize
=
output
->
Size
;
HeapFree
(
GetProcessHeap
(),
0
,
output
);
if
(
GetLastError
()
!=
ERROR_MORE_DATA
)
return
NULL
;
...
...
@@ -2024,6 +2027,7 @@ HANDLE WINAPI FindFirstVolumeA(LPSTR volume, DWORD len)
HANDLE
WINAPI
FindFirstVolumeW
(
LPWSTR
volume
,
DWORD
len
)
{
DWORD
size
=
1024
;
DWORD
br
;
HANDLE
mgr
=
CreateFileW
(
MOUNTMGR_DOS_DEVICE_NAME
,
0
,
FILE_SHARE_READ
|
FILE_SHARE_WRITE
,
NULL
,
OPEN_EXISTING
,
0
,
0
);
if
(
mgr
==
INVALID_HANDLE_VALUE
)
return
INVALID_HANDLE_VALUE
;
...
...
@@ -2041,7 +2045,7 @@ HANDLE WINAPI FindFirstVolumeW( LPWSTR volume, DWORD len )
memset
(
&
input
,
0
,
sizeof
(
input
)
);
if
(
!
DeviceIoControl
(
mgr
,
IOCTL_MOUNTMGR_QUERY_POINTS
,
&
input
,
sizeof
(
input
),
output
,
size
,
NULL
,
NULL
))
output
,
size
,
&
br
,
NULL
))
{
if
(
GetLastError
()
!=
ERROR_MORE_DATA
)
break
;
size
=
output
->
Size
;
...
...
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