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
4723b6b8
Commit
4723b6b8
authored
Aug 15, 2022
by
Piotr Caban
Committed by
Alexandre Julliard
Aug 16, 2022
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winspool.drv: Ignore device name if printer handle is passed in DocumentProperties.
parent
5fabd968
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
5 additions
and
1 deletion
+5
-1
info.c
dlls/winspool.drv/info.c
+1
-1
info.c
dlls/winspool.drv/tests/info.c
+4
-0
No files found.
dlls/winspool.drv/info.c
View file @
4723b6b8
...
...
@@ -1889,7 +1889,7 @@ LONG WINAPI DocumentPropertiesW(HWND hWnd, HANDLE hPrinter,
TRACE
(
"(%p,%p,%s,%p,%p,%ld)
\n
"
,
hWnd
,
hPrinter
,
debugstr_w
(
pDeviceName
),
pDevModeOutput
,
pDevModeInput
,
fMode
);
device
=
pDeviceName
&&
pDeviceName
[
0
]
?
pDeviceName
:
get_opened_printer_name
(
hPrinter
)
;
device
=
hPrinter
?
get_opened_printer_name
(
hPrinter
)
:
pDeviceName
;
if
(
!
device
)
{
ERR
(
"no device name
\n
"
);
return
-
1
;
...
...
dlls/winspool.drv/tests/info.c
View file @
4723b6b8
...
...
@@ -2679,6 +2679,7 @@ static void test_DocumentProperties(void)
LONG
dm_size
,
ret
;
DEVMODEA
*
dm
;
char
empty_str
[]
=
""
;
char
non_existing_str
[]
=
"non existing printer"
;
if
(
!
default_printer
)
{
...
...
@@ -2707,6 +2708,9 @@ static void test_DocumentProperties(void)
ret
=
DocumentPropertiesA
(
0
,
hprn
,
empty_str
,
dm
,
dm
,
DM_OUT_BUFFER
);
ok
(
ret
==
IDOK
,
"DocumentPropertiesA ret value %ld != expected IDOK
\n
"
,
ret
);
ret
=
DocumentPropertiesA
(
0
,
hprn
,
non_existing_str
,
dm
,
dm
,
DM_OUT_BUFFER
);
ok
(
ret
==
IDOK
,
"DocumentPropertiesA ret value %ld != expected IDOK
\n
"
,
ret
);
test_DEVMODEA
(
dm
,
dm_size
,
default_printer
);
HeapFree
(
GetProcessHeap
(),
0
,
dm
);
...
...
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