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
c55f8f35
Commit
c55f8f35
authored
Mar 08, 2023
by
Gabriel Ivăncescu
Committed by
Alexandre Julliard
Mar 08, 2023
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
kernel32: Fix GetNumberFormatA when input length is 0.
Fixes a regression introduced by
b6bf69ef
. Signed-off-by:
Gabriel Ivăncescu
<
gabrielopcode@gmail.com
>
parent
13afaa7c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
4 deletions
+2
-4
locale.c
dlls/kernel32/locale.c
+2
-4
No files found.
dlls/kernel32/locale.c
View file @
c55f8f35
...
...
@@ -430,8 +430,6 @@ int WINAPI GetNumberFormatA( LCID lcid, DWORD flags, const char *value,
}
MultiByteToWideChar
(
cp
,
0
,
value
,
-
1
,
input
,
ARRAY_SIZE
(
input
)
);
if
(
len
>
(
int
)
ARRAY_SIZE
(
output
))
len
=
ARRAY_SIZE
(
output
);
if
(
format
)
{
NUMBERFMTW
fmt
;
...
...
@@ -455,9 +453,9 @@ int WINAPI GetNumberFormatA( LCID lcid, DWORD flags, const char *value,
fmt
.
NegativeOrder
=
format
->
NegativeOrder
;
fmt
.
lpDecimalSep
=
fmt_decimal
;
fmt
.
lpThousandSep
=
fmt_thousand
;
ret
=
GetNumberFormatW
(
lcid
,
flags
,
input
,
&
fmt
,
output
,
len
);
ret
=
GetNumberFormatW
(
lcid
,
flags
,
input
,
&
fmt
,
output
,
ARRAY_SIZE
(
output
)
);
}
else
ret
=
GetNumberFormatW
(
lcid
,
flags
,
input
,
NULL
,
output
,
len
);
else
ret
=
GetNumberFormatW
(
lcid
,
flags
,
input
,
NULL
,
output
,
ARRAY_SIZE
(
output
)
);
if
(
ret
)
ret
=
WideCharToMultiByte
(
cp
,
0
,
output
,
-
1
,
buffer
,
len
,
0
,
0
);
return
ret
;
...
...
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