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
856800c8
Commit
856800c8
authored
Feb 04, 2008
by
James Hawkins
Committed by
Alexandre Julliard
Feb 05, 2008
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msi: Translate ERROR_BAD_PATHNAME into ERROR_FILE_NOT_FOUND.
parent
5d46eeac
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
7 deletions
+10
-7
msi.c
dlls/msi/msi.c
+8
-2
msi.c
dlls/msi/tests/msi.c
+2
-5
No files found.
dlls/msi/msi.c
View file @
856800c8
...
...
@@ -1569,7 +1569,7 @@ UINT WINAPI MsiGetFileVersionW(LPCWSTR szFilePath, LPWSTR lpVersionBuf,
'%'
,
'd'
,
'.'
,
'%'
,
'd'
,
'.'
,
'%'
,
'd'
,
'.'
,
'%'
,
'd'
,
0
};
static
const
WCHAR
szLangFormat
[]
=
{
'%'
,
'd'
,
0
};
UINT
ret
=
0
;
DWORD
dwVerLen
;
DWORD
dwVerLen
,
gle
;
LPVOID
lpVer
=
NULL
;
VS_FIXEDFILEINFO
*
ffi
;
UINT
puLen
;
...
...
@@ -1581,7 +1581,13 @@ UINT WINAPI MsiGetFileVersionW(LPCWSTR szFilePath, LPWSTR lpVersionBuf,
dwVerLen
=
GetFileVersionInfoSizeW
(
szFilePath
,
NULL
);
if
(
!
dwVerLen
)
return
GetLastError
();
{
gle
=
GetLastError
();
if
(
gle
==
ERROR_BAD_PATHNAME
)
return
ERROR_FILE_NOT_FOUND
;
return
gle
;
}
lpVer
=
msi_alloc
(
dwVerLen
);
if
(
!
lpVer
)
...
...
dlls/msi/tests/msi.c
View file @
856800c8
...
...
@@ -1847,17 +1847,14 @@ static void test_MsiGetFileVersion(void)
lstrcpyA
(
version
,
"version"
);
lstrcpyA
(
lang
,
"lang"
);
r
=
MsiGetFileVersionA
(
""
,
version
,
&
versz
,
lang
,
&
langsz
);
ok
(
r
==
ERROR_FILE_NOT_FOUND
,
"Expected ERROR_FILE_NOT_FOUND, got %d
\n
"
,
r
);
ok
(
!
lstrcmpA
(
version
,
"version"
),
"Expected version to be unchanged, got %s
\n
"
,
version
);
ok
(
versz
==
MAX_PATH
,
"Expected %d, got %d
\n
"
,
MAX_PATH
,
versz
);
ok
(
!
lstrcmpA
(
lang
,
"lang"
),
"Expected lang to be unchanged, got %s
\n
"
,
lang
);
ok
(
langsz
==
MAX_PATH
,
"Expected %d, got %d
\n
"
,
MAX_PATH
,
langsz
);
todo_wine
{
ok
(
r
==
ERROR_FILE_NOT_FOUND
,
"Expected ERROR_FILE_NOT_FOUND, got %d
\n
"
,
r
);
}
/* nonexistent szFilePath */
versz
=
MAX_PATH
;
...
...
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