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
23389127
Commit
23389127
authored
Mar 31, 2021
by
Alexandre Julliard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
gdi32: Try to load the printer driver from the printer driver directory.
Signed-off-by:
Alexandre Julliard
<
julliard@winehq.org
>
parent
efdd6f46
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
1 deletion
+21
-1
driver.c
dlls/gdi32/driver.c
+21
-1
No files found.
dlls/gdi32/driver.c
View file @
23389127
...
...
@@ -177,6 +177,18 @@ static void release_display_device_init_mutex( HANDLE mutex )
CloseHandle
(
mutex
);
}
#ifdef __i386__
static
const
WCHAR
printer_env
[]
=
L"w32x86"
;
#elif defined __x86_64__
static
const
WCHAR
printer_env
[]
=
L"x64"
;
#elif defined __arm__
static
const
WCHAR
printer_env
[]
=
L"arm"
;
#elif defined __aarch64__
static
const
WCHAR
printer_env
[]
=
L"arm64"
;
#else
#error not defined for this cpu
#endif
/**********************************************************************
* DRIVER_load_driver
*/
...
...
@@ -200,7 +212,15 @@ const struct gdi_dc_funcs *DRIVER_load_driver( LPCWSTR name )
LeaveCriticalSection
(
&
driver_section
);
}
if
(
!
(
module
=
LoadLibraryW
(
name
)))
return
NULL
;
if
(
!
(
module
=
LoadLibraryW
(
name
)))
{
WCHAR
path
[
MAX_PATH
];
GetSystemDirectoryW
(
path
,
MAX_PATH
);
swprintf
(
path
+
wcslen
(
path
),
MAX_PATH
-
wcslen
(
path
),
L"
\\
spool
\\
drivers
\\
%s
\\
3
\\
%s"
,
printer_env
,
name
);
if
(
!
(
module
=
LoadLibraryW
(
path
)))
return
NULL
;
}
if
(
!
(
new_driver
=
create_driver
(
module
)))
{
...
...
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