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
27aacaa7
Commit
27aacaa7
authored
Feb 07, 2022
by
Eric Pouech
Committed by
Alexandre Julliard
Feb 07, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winecfg: Enable compilation with long types.
Signed-off-by:
Eric Pouech
<
eric.pouech@gmail.com
>
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
5686741f
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
22 additions
and
23 deletions
+22
-23
Makefile.in
programs/winecfg/Makefile.in
+0
-1
audio.c
programs/winecfg/audio.c
+4
-4
drive.c
programs/winecfg/drive.c
+7
-7
driveui.c
programs/winecfg/driveui.c
+2
-2
main.c
programs/winecfg/main.c
+1
-1
winecfg.c
programs/winecfg/winecfg.c
+7
-7
x11drvdlg.c
programs/winecfg/x11drvdlg.c
+1
-1
No files found.
programs/winecfg/Makefile.in
View file @
27aacaa7
EXTRADEFS
=
-DWINE_NO_LONG_TYPES
MODULE
=
winecfg.exe
MODULE
=
winecfg.exe
IMPORTS
=
uuid comdlg32 comctl32 shell32 ole32 winmm shlwapi uxtheme user32 gdi32 advapi32
IMPORTS
=
uuid comdlg32 comctl32 shell32 ole32 winmm shlwapi uxtheme user32 gdi32 advapi32
...
...
programs/winecfg/audio.c
View file @
27aacaa7
...
@@ -412,7 +412,7 @@ static void apply_speaker_configs(void)
...
@@ -412,7 +412,7 @@ static void apply_speaker_configs(void)
CLSCTX_INPROC_SERVER
,
&
IID_IMMDeviceEnumerator
,
(
void
**
)
&
devenum
);
CLSCTX_INPROC_SERVER
,
&
IID_IMMDeviceEnumerator
,
(
void
**
)
&
devenum
);
if
(
FAILED
(
hr
)){
if
(
FAILED
(
hr
)){
ERR
(
"Unable to create MMDeviceEnumerator: 0x%08x
\n
"
,
hr
);
ERR
(
"Unable to create MMDeviceEnumerator: 0x%08
l
x
\n
"
,
hr
);
return
;
return
;
}
}
...
@@ -423,14 +423,14 @@ static void apply_speaker_configs(void)
...
@@ -423,14 +423,14 @@ static void apply_speaker_configs(void)
hr
=
IMMDeviceEnumerator_GetDevice
(
devenum
,
render_devs
[
i
].
id
,
&
dev
);
hr
=
IMMDeviceEnumerator_GetDevice
(
devenum
,
render_devs
[
i
].
id
,
&
dev
);
if
(
FAILED
(
hr
)){
if
(
FAILED
(
hr
)){
WARN
(
"Could not get MMDevice for %s: 0x%08x
\n
"
,
wine_dbgstr_w
(
render_devs
[
i
].
id
),
hr
);
WARN
(
"Could not get MMDevice for %s: 0x%08
l
x
\n
"
,
wine_dbgstr_w
(
render_devs
[
i
].
id
),
hr
);
continue
;
continue
;
}
}
hr
=
IMMDevice_OpenPropertyStore
(
dev
,
STGM_WRITE
,
&
ps
);
hr
=
IMMDevice_OpenPropertyStore
(
dev
,
STGM_WRITE
,
&
ps
);
if
(
FAILED
(
hr
)){
if
(
FAILED
(
hr
)){
WARN
(
"Could not open property store for %s: 0x%08x
\n
"
,
wine_dbgstr_w
(
render_devs
[
i
].
id
),
hr
);
WARN
(
"Could not open property store for %s: 0x%08
l
x
\n
"
,
wine_dbgstr_w
(
render_devs
[
i
].
id
),
hr
);
IMMDevice_Release
(
dev
);
IMMDevice_Release
(
dev
);
continue
;
continue
;
}
}
...
@@ -440,7 +440,7 @@ static void apply_speaker_configs(void)
...
@@ -440,7 +440,7 @@ static void apply_speaker_configs(void)
hr
=
IPropertyStore_SetValue
(
ps
,
&
PKEY_AudioEndpoint_PhysicalSpeakers
,
&
pv
);
hr
=
IPropertyStore_SetValue
(
ps
,
&
PKEY_AudioEndpoint_PhysicalSpeakers
,
&
pv
);
if
(
FAILED
(
hr
))
if
(
FAILED
(
hr
))
WARN
(
"IPropertyStore_SetValue failed for %s: 0x%08x
\n
"
,
wine_dbgstr_w
(
render_devs
[
i
].
id
),
hr
);
WARN
(
"IPropertyStore_SetValue failed for %s: 0x%08
l
x
\n
"
,
wine_dbgstr_w
(
render_devs
[
i
].
id
),
hr
);
IPropertyStore_Release
(
ps
);
IPropertyStore_Release
(
ps
);
IMMDevice_Release
(
dev
);
IMMDevice_Release
(
dev
);
...
...
programs/winecfg/drive.c
View file @
27aacaa7
...
@@ -85,7 +85,7 @@ ULONG drive_available_mask(char letter)
...
@@ -85,7 +85,7 @@ ULONG drive_available_mask(char letter)
result
=
~
result
;
result
=
~
result
;
if
(
letter
)
result
|=
DRIVE_MASK_BIT
(
letter
);
if
(
letter
)
result
|=
DRIVE_MASK_BIT
(
letter
);
WINE_TRACE
(
"finished drive letter loop with %x
\n
"
,
result
);
WINE_TRACE
(
"finished drive letter loop with %
l
x
\n
"
,
result
);
return
result
;
return
result
;
}
}
...
@@ -97,7 +97,7 @@ BOOL add_drive(char letter, const char *targetpath, const char *device, const WC
...
@@ -97,7 +97,7 @@ BOOL add_drive(char letter, const char *targetpath, const char *device, const WC
if
(
drives
[
driveIndex
].
in_use
)
if
(
drives
[
driveIndex
].
in_use
)
return
FALSE
;
return
FALSE
;
WINE_TRACE
(
"letter == '%c', unixpath == %s, device == %s, label == %s, serial == %08
x, type == %
d
\n
"
,
WINE_TRACE
(
"letter == '%c', unixpath == %s, device == %s, label == %s, serial == %08
lx, type == %l
d
\n
"
,
letter
,
wine_dbgstr_a
(
targetpath
),
wine_dbgstr_a
(
device
),
letter
,
wine_dbgstr_a
(
targetpath
),
wine_dbgstr_a
(
device
),
wine_dbgstr_w
(
label
),
serial
,
type
);
wine_dbgstr_w
(
label
),
serial
,
type
);
...
@@ -183,7 +183,7 @@ static void set_drive_serial( WCHAR letter, DWORD serial )
...
@@ -183,7 +183,7 @@ static void set_drive_serial( WCHAR letter, DWORD serial )
HANDLE
hFile
;
HANDLE
hFile
;
filename
[
0
]
=
letter
;
filename
[
0
]
=
letter
;
WINE_TRACE
(
"Putting serial number of %08X into file %s
\n
"
,
serial
,
wine_dbgstr_w
(
filename
));
WINE_TRACE
(
"Putting serial number of %08
l
X into file %s
\n
"
,
serial
,
wine_dbgstr_w
(
filename
));
hFile
=
CreateFileW
(
filename
,
GENERIC_WRITE
,
FILE_SHARE_READ
,
NULL
,
hFile
=
CreateFileW
(
filename
,
GENERIC_WRITE
,
FILE_SHARE_READ
,
NULL
,
CREATE_ALWAYS
,
FILE_ATTRIBUTE_NORMAL
,
NULL
);
CREATE_ALWAYS
,
FILE_ATTRIBUTE_NORMAL
,
NULL
);
if
(
hFile
!=
INVALID_HANDLE_VALUE
)
if
(
hFile
!=
INVALID_HANDLE_VALUE
)
...
@@ -191,7 +191,7 @@ static void set_drive_serial( WCHAR letter, DWORD serial )
...
@@ -191,7 +191,7 @@ static void set_drive_serial( WCHAR letter, DWORD serial )
DWORD
w
;
DWORD
w
;
char
buffer
[
16
];
char
buffer
[
16
];
sprintf
(
buffer
,
"%X
\n
"
,
serial
);
sprintf
(
buffer
,
"%
l
X
\n
"
,
serial
);
WriteFile
(
hFile
,
buffer
,
strlen
(
buffer
),
&
w
,
NULL
);
WriteFile
(
hFile
,
buffer
,
strlen
(
buffer
),
&
w
,
NULL
);
CloseHandle
(
hFile
);
CloseHandle
(
hFile
);
}
}
...
@@ -204,7 +204,7 @@ static HANDLE open_mountmgr(void)
...
@@ -204,7 +204,7 @@ static HANDLE open_mountmgr(void)
if
((
ret
=
CreateFileW
(
MOUNTMGR_DOS_DEVICE_NAME
,
GENERIC_READ
|
GENERIC_WRITE
,
if
((
ret
=
CreateFileW
(
MOUNTMGR_DOS_DEVICE_NAME
,
GENERIC_READ
|
GENERIC_WRITE
,
FILE_SHARE_READ
|
FILE_SHARE_WRITE
,
NULL
,
OPEN_EXISTING
,
FILE_SHARE_READ
|
FILE_SHARE_WRITE
,
NULL
,
OPEN_EXISTING
,
0
,
0
))
==
INVALID_HANDLE_VALUE
)
0
,
0
))
==
INVALID_HANDLE_VALUE
)
WINE_ERR
(
"failed to open mount manager err %u
\n
"
,
GetLastError
()
);
WINE_ERR
(
"failed to open mount manager err %
l
u
\n
"
,
GetLastError
()
);
return
ret
;
return
ret
;
}
}
...
@@ -315,10 +315,10 @@ void apply_drive_changes(void)
...
@@ -315,10 +315,10 @@ void apply_drive_changes(void)
{
{
set_drive_label
(
drives
[
i
].
letter
,
drives
[
i
].
label
);
set_drive_label
(
drives
[
i
].
letter
,
drives
[
i
].
label
);
if
(
drives
[
i
].
in_use
)
set_drive_serial
(
drives
[
i
].
letter
,
drives
[
i
].
serial
);
if
(
drives
[
i
].
in_use
)
set_drive_serial
(
drives
[
i
].
letter
,
drives
[
i
].
serial
);
WINE_TRACE
(
"set drive %c: to %s type %u
\n
"
,
'a'
+
i
,
WINE_TRACE
(
"set drive %c: to %s type %
l
u
\n
"
,
'a'
+
i
,
wine_dbgstr_a
(
drives
[
i
].
unixpath
),
drives
[
i
].
type
);
wine_dbgstr_a
(
drives
[
i
].
unixpath
),
drives
[
i
].
type
);
}
}
else
WINE_WARN
(
"failed to set drive %c: to %s type %
u err %
u
\n
"
,
'a'
+
i
,
else
WINE_WARN
(
"failed to set drive %c: to %s type %
lu err %l
u
\n
"
,
'a'
+
i
,
wine_dbgstr_a
(
drives
[
i
].
unixpath
),
drives
[
i
].
type
,
GetLastError
()
);
wine_dbgstr_a
(
drives
[
i
].
unixpath
),
drives
[
i
].
type
,
GetLastError
()
);
HeapFree
(
GetProcessHeap
(),
0
,
ioctl
);
HeapFree
(
GetProcessHeap
(),
0
,
ioctl
);
}
}
...
...
programs/winecfg/driveui.c
View file @
27aacaa7
...
@@ -463,7 +463,7 @@ static void update_controls(HWND dialog)
...
@@ -463,7 +463,7 @@ static void update_controls(HWND dialog)
set_textW
(
dialog
,
IDC_EDIT_LABEL
,
current_drive
->
label
?
current_drive
->
label
:
emptyW
);
set_textW
(
dialog
,
IDC_EDIT_LABEL
,
current_drive
->
label
?
current_drive
->
label
:
emptyW
);
/* set serial edit text */
/* set serial edit text */
sprintf
(
serial
,
"%X"
,
current_drive
->
serial
);
sprintf
(
serial
,
"%
l
X"
,
current_drive
->
serial
);
set_text
(
dialog
,
IDC_EDIT_SERIAL
,
serial
);
set_text
(
dialog
,
IDC_EDIT_SERIAL
,
serial
);
set_text
(
dialog
,
IDC_EDIT_DEVICE
,
current_drive
->
device
);
set_text
(
dialog
,
IDC_EDIT_DEVICE
,
current_drive
->
device
);
...
@@ -542,7 +542,7 @@ static void on_edit_changed(HWND dialog, WORD id)
...
@@ -542,7 +542,7 @@ static void on_edit_changed(HWND dialog, WORD id)
HeapFree
(
GetProcessHeap
(),
0
,
serial
);
HeapFree
(
GetProcessHeap
(),
0
,
serial
);
current_drive
->
modified
=
TRUE
;
current_drive
->
modified
=
TRUE
;
WINE_TRACE
(
"set serial to %08X
\n
"
,
current_drive
->
serial
);
WINE_TRACE
(
"set serial to %08
l
X
\n
"
,
current_drive
->
serial
);
/* enable the apply button */
/* enable the apply button */
SendMessageW
(
GetParent
(
dialog
),
PSM_CHANGED
,
(
WPARAM
)
dialog
,
0
);
SendMessageW
(
GetParent
(
dialog
),
PSM_CHANGED
,
(
WPARAM
)
dialog
,
0
);
...
...
programs/winecfg/main.c
View file @
27aacaa7
...
@@ -247,7 +247,7 @@ wWinMain (HINSTANCE hInstance, HINSTANCE hPrev, LPWSTR cmdline, int nShow)
...
@@ -247,7 +247,7 @@ wWinMain (HINSTANCE hInstance, HINSTANCE hPrev, LPWSTR cmdline, int nShow)
GetExitCodeProcess
(
pi
.
hProcess
,
&
exit_code
);
GetExitCodeProcess
(
pi
.
hProcess
,
&
exit_code
);
ExitProcess
(
exit_code
);
ExitProcess
(
exit_code
);
}
}
else
WINE_ERR
(
"failed to restart 64-bit %s, err %d
\n
"
,
wine_dbgstr_w
(
filename
),
GetLastError
()
);
else
WINE_ERR
(
"failed to restart 64-bit %s, err %
l
d
\n
"
,
wine_dbgstr_w
(
filename
),
GetLastError
()
);
Wow64RevertWow64FsRedirection
(
redir
);
Wow64RevertWow64FsRedirection
(
redir
);
}
}
...
...
programs/winecfg/winecfg.c
View file @
27aacaa7
...
@@ -120,7 +120,7 @@ static WCHAR *get_config_key (HKEY root, const WCHAR *subkey, const WCHAR *name,
...
@@ -120,7 +120,7 @@ static WCHAR *get_config_key (HKEY root, const WCHAR *subkey, const WCHAR *name,
}
}
else
else
{
{
WINE_ERR
(
"RegOpenKey failed on wine config key (res=%d)
\n
"
,
res
);
WINE_ERR
(
"RegOpenKey failed on wine config key (res=%
l
d)
\n
"
,
res
);
}
}
goto
end
;
goto
end
;
}
}
...
@@ -133,7 +133,7 @@ static WCHAR *get_config_key (HKEY root, const WCHAR *subkey, const WCHAR *name,
...
@@ -133,7 +133,7 @@ static WCHAR *get_config_key (HKEY root, const WCHAR *subkey, const WCHAR *name,
goto
end
;
goto
end
;
}
else
if
(
res
!=
ERROR_SUCCESS
)
}
else
if
(
res
!=
ERROR_SUCCESS
)
{
{
WINE_ERR
(
"Couldn't query value's length (res=%d)
\n
"
,
res
);
WINE_ERR
(
"Couldn't query value's length (res=%
l
d)
\n
"
,
res
);
goto
end
;
goto
end
;
}
}
...
@@ -164,7 +164,7 @@ static int set_config_key(HKEY root, const WCHAR *subkey, REGSAM access, const W
...
@@ -164,7 +164,7 @@ static int set_config_key(HKEY root, const WCHAR *subkey, REGSAM access, const W
DWORD
res
=
1
;
DWORD
res
=
1
;
HKEY
key
=
NULL
;
HKEY
key
=
NULL
;
WINE_TRACE
(
"subkey=%s: name=%s, value=%p, type=%d
\n
"
,
wine_dbgstr_w
(
subkey
),
WINE_TRACE
(
"subkey=%s: name=%s, value=%p, type=%
l
d
\n
"
,
wine_dbgstr_w
(
subkey
),
wine_dbgstr_w
(
name
),
value
,
type
);
wine_dbgstr_w
(
name
),
value
,
type
);
assert
(
subkey
!=
NULL
);
assert
(
subkey
!=
NULL
);
...
@@ -189,7 +189,7 @@ static int set_config_key(HKEY root, const WCHAR *subkey, REGSAM access, const W
...
@@ -189,7 +189,7 @@ static int set_config_key(HKEY root, const WCHAR *subkey, REGSAM access, const W
end:
end:
if
(
key
&&
key
!=
root
)
RegCloseKey
(
key
);
if
(
key
&&
key
!=
root
)
RegCloseKey
(
key
);
if
(
res
!=
0
)
if
(
res
!=
0
)
WINE_ERR
(
"Unable to set configuration key %s in section %s, res=%d
\n
"
,
WINE_ERR
(
"Unable to set configuration key %s in section %s, res=%
l
d
\n
"
,
wine_dbgstr_w
(
name
),
wine_dbgstr_w
(
subkey
),
res
);
wine_dbgstr_w
(
name
),
wine_dbgstr_w
(
subkey
),
res
);
return
res
;
return
res
;
}
}
...
@@ -430,13 +430,13 @@ WCHAR **enumerate_values(HKEY root, const WCHAR *path)
...
@@ -430,13 +430,13 @@ WCHAR **enumerate_values(HKEY root, const WCHAR *path)
else
values
=
HeapAlloc
(
GetProcessHeap
(),
0
,
sizeof
(
WCHAR
*
));
else
values
=
HeapAlloc
(
GetProcessHeap
(),
0
,
sizeof
(
WCHAR
*
));
values
[
valueslen
++
]
=
strdupW
(
name
);
values
[
valueslen
++
]
=
strdupW
(
name
);
WINE_TRACE
(
"valueslen is now %d
\n
"
,
valueslen
);
WINE_TRACE
(
"valueslen is now %
l
d
\n
"
,
valueslen
);
i
++
;
i
++
;
}
}
}
}
else
else
{
{
WINE_WARN
(
"failed opening registry key %s, res=0x%x
\n
"
,
WINE_WARN
(
"failed opening registry key %s, res=0x%
l
x
\n
"
,
wine_dbgstr_w
(
path
),
res
);
wine_dbgstr_w
(
path
),
res
);
}
}
...
@@ -610,7 +610,7 @@ BOOL initialize(HINSTANCE hInstance)
...
@@ -610,7 +610,7 @@ BOOL initialize(HINSTANCE hInstance)
DWORD
res
=
RegCreateKeyW
(
HKEY_CURRENT_USER
,
WINE_KEY_ROOT
,
&
config_key
);
DWORD
res
=
RegCreateKeyW
(
HKEY_CURRENT_USER
,
WINE_KEY_ROOT
,
&
config_key
);
if
(
res
!=
ERROR_SUCCESS
)
{
if
(
res
!=
ERROR_SUCCESS
)
{
WINE_ERR
(
"RegOpenKey failed on wine config key (%d)
\n
"
,
res
);
WINE_ERR
(
"RegOpenKey failed on wine config key (%
l
d)
\n
"
,
res
);
return
TRUE
;
return
TRUE
;
}
}
...
...
programs/winecfg/x11drvdlg.c
View file @
27aacaa7
...
@@ -245,7 +245,7 @@ static void init_dpi_editbox(HWND hDlg)
...
@@ -245,7 +245,7 @@ static void init_dpi_editbox(HWND hDlg)
updating_ui
=
TRUE
;
updating_ui
=
TRUE
;
dwLogpixels
=
read_logpixels_reg
();
dwLogpixels
=
read_logpixels_reg
();
WINE_TRACE
(
"%u
\n
"
,
dwLogpixels
);
WINE_TRACE
(
"%
l
u
\n
"
,
dwLogpixels
);
SetDlgItemInt
(
hDlg
,
IDC_RES_DPIEDIT
,
dwLogpixels
,
FALSE
);
SetDlgItemInt
(
hDlg
,
IDC_RES_DPIEDIT
,
dwLogpixels
,
FALSE
);
...
...
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