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
cfc4082b
Commit
cfc4082b
authored
Oct 13, 2002
by
Carlos
Committed by
Alexandre Julliard
Oct 13, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Avoid crashes when ofnW->lpstrFile is null.
parent
618c1841
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
filedlg.c
dlls/commdlg/filedlg.c
+4
-3
No files found.
dlls/commdlg/filedlg.c
View file @
cfc4082b
...
...
@@ -669,8 +669,8 @@ void FILEDLG_UpdateResult(LFSPRIVATE lfs, WCHAR *tmpstr)
LPOPENFILENAME16
ofn16
=
lfs
->
ofn16
;
char
*
dest
=
MapSL
(
ofn16
->
lpstrFile
);
if
(
!
WideCharToMultiByte
(
CP_ACP
,
0
,
ofnW
->
lpstrFile
,
-
1
,
tmp
,
ofnW
->
nMaxFile
,
NULL
,
NULL
))
tmp
[
ofnW
->
nMaxFile
-
1
]
=
0
;
tmp
,
sizeof
(
tmp
)
,
NULL
,
NULL
))
tmp
[
sizeof
(
tmp
)
-
1
]
=
0
;
GetShortPathNameA
(
tmp
,
dest
,
ofn16
->
nMaxFile
);
/* the same procedure as every year... */
...
...
@@ -685,7 +685,8 @@ void FILEDLG_UpdateResult(LFSPRIVATE lfs, WCHAR *tmpstr)
}
if
(
lfs
->
ofnA
)
{
if
(
!
WideCharToMultiByte
(
CP_ACP
,
0
,
ofnW
->
lpstrFile
,
-
1
,
if
(
ofnW
->
nMaxFile
&&
!
WideCharToMultiByte
(
CP_ACP
,
0
,
ofnW
->
lpstrFile
,
-
1
,
lfs
->
ofnA
->
lpstrFile
,
ofnW
->
nMaxFile
,
NULL
,
NULL
))
lfs
->
ofnA
->
lpstrFile
[
ofnW
->
nMaxFile
-
1
]
=
0
;
lfs
->
ofnA
->
nFileOffset
=
ofnW
->
nFileOffset
;
...
...
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