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
914e78ae
Commit
914e78ae
authored
Dec 01, 2007
by
Vitaly Lipatov
Committed by
Alexandre Julliard
Dec 05, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
winspool.drv: Fix buffer sizes.
parent
2dcb7b5d
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
3 deletions
+3
-3
info.c
dlls/winspool.drv/info.c
+3
-3
No files found.
dlls/winspool.drv/info.c
View file @
914e78ae
...
...
@@ -1626,7 +1626,7 @@ void WINSPOOL_LoadSystemPrinters(void)
if
(
RegQueryInfoKeyA
(
hkeyPrinters
,
NULL
,
NULL
,
NULL
,
&
num
,
NULL
,
NULL
,
NULL
,
NULL
,
NULL
,
NULL
,
NULL
)
==
ERROR_SUCCESS
)
{
for
(
i
=
0
;
i
<
num
;
i
++
)
{
if
(
RegEnumKeyW
(
hkeyPrinters
,
i
,
PrinterName
,
sizeof
(
PrinterName
))
==
ERROR_SUCCESS
)
{
if
(
RegEnumKeyW
(
hkeyPrinters
,
i
,
PrinterName
,
sizeof
(
PrinterName
)
/
sizeof
(
PrinterName
[
0
])
)
==
ERROR_SUCCESS
)
{
if
(
RegOpenKeyW
(
hkeyPrinters
,
PrinterName
,
&
hkey
)
==
ERROR_SUCCESS
)
{
if
(
RegQueryValueExW
(
hkey
,
NameW
,
0
,
0
,
0
,
&
needed
)
==
ERROR_FILE_NOT_FOUND
)
{
set_reg_szW
(
hkey
,
NameW
,
PrinterName
);
...
...
@@ -4276,7 +4276,7 @@ static BOOL WINSPOOL_EnumPrinters(DWORD dwType, LPWSTR lpszName,
pi
=
(
used
<=
cbBuf
)
?
lpbPrinters
:
NULL
;
for
(
i
=
0
;
i
<
number
;
i
++
)
{
if
(
RegEnumKeyW
(
hkeyPrinters
,
i
,
PrinterName
,
sizeof
(
PrinterName
))
!=
if
(
RegEnumKeyW
(
hkeyPrinters
,
i
,
PrinterName
,
sizeof
(
PrinterName
)
/
sizeof
(
PrinterName
[
0
])
)
!=
ERROR_SUCCESS
)
{
ERR
(
"Can't enum key number %d
\n
"
,
i
);
RegCloseKey
(
hkeyPrinters
);
...
...
@@ -5177,7 +5177,7 @@ static BOOL WINSPOOL_EnumPrinterDrivers(LPWSTR pName, LPCWSTR pEnvironment,
for
(
i
=
0
,
ptr
=
(
pDriverInfo
&&
(
cbBuf
>=
size
))
?
pDriverInfo
:
NULL
;
i
<
number
;
i
++
,
ptr
=
(
ptr
&&
(
cbBuf
>=
size
*
i
))
?
ptr
+
size
:
NULL
)
{
if
(
RegEnumKeyW
(
hkeyDrivers
,
i
,
DriverNameW
,
sizeof
(
DriverNameW
))
if
(
RegEnumKeyW
(
hkeyDrivers
,
i
,
DriverNameW
,
sizeof
(
DriverNameW
)
/
sizeof
(
DriverNameW
[
0
])
)
!=
ERROR_SUCCESS
)
{
ERR
(
"Can't enum key number %d
\n
"
,
i
);
RegCloseKey
(
hkeyDrivers
);
...
...
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