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
2ad04cae
Commit
2ad04cae
authored
Jun 25, 2006
by
Andrey Turkin
Committed by
Alexandre Julliard
Jun 26, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msi: Disable some path validity checks in MsiSetTargetPath.
parent
27bfdc2a
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
18 deletions
+2
-18
install.c
dlls/msi/install.c
+2
-12
package.c
dlls/msi/tests/package.c
+0
-6
No files found.
dlls/msi/install.c
View file @
2ad04cae
...
...
@@ -336,24 +336,14 @@ UINT MSI_SetTargetPathW(MSIPACKAGE *package, LPCWSTR szFolder,
attrib
=
GetFileAttributesW
(
szFolderPath
);
if
(
attrib
!=
INVALID_FILE_ATTRIBUTES
&&
(
!
(
attrib
&
FILE_ATTRIBUTE_DIRECTORY
)
||
attrib
&
FILE_ATTRIBUTE_OFFLINE
||
attrib
&
FILE_ATTRIBUTE_READONLY
))
(
attrib
&
FILE_ATTRIBUTE_OFFLINE
||
attrib
&
FILE_ATTRIBUTE_READONLY
))
/* actually native MSI tests writeability by making temporary files at each drive */
return
ERROR_FUNCTION_FAILED
;
path
=
resolve_folder
(
package
,
szFolder
,
FALSE
,
FALSE
,
&
folder
);
if
(
!
path
)
return
ERROR_DIRECTORY
;
if
(
attrib
==
INVALID_FILE_ATTRIBUTES
)
{
if
(
!
CreateDirectoryW
(
szFolderPath
,
NULL
))
{
msi_free
(
path
);
return
ERROR_FUNCTION_FAILED
;
}
RemoveDirectoryW
(
szFolderPath
);
}
msi_free
(
folder
->
Property
);
folder
->
Property
=
build_directory_name
(
2
,
szFolderPath
,
NULL
);
...
...
dlls/msi/tests/package.c
View file @
2ad04cae
...
...
@@ -404,14 +404,10 @@ static void test_settargetpath(void)
{
sprintf
(
tempdir
,
"%s
\\
subdir"
,
buffer
);
r
=
MsiSetTargetPath
(
hpkg
,
"TARGETDIR"
,
buffer
);
todo_wine
{
ok
(
r
==
ERROR_SUCCESS
,
"MsiSetTargetPath on file returned %d
\n
"
,
r
);
}
r
=
MsiSetTargetPath
(
hpkg
,
"TARGETDIR"
,
tempdir
);
todo_wine
{
ok
(
r
==
ERROR_SUCCESS
,
"MsiSetTargetPath on 'subdir' of file returned %d
\n
"
,
r
);
}
DeleteFile
(
buffer
);
...
...
@@ -422,9 +418,7 @@ static void test_settargetpath(void)
ok
(
r
==
INVALID_FILE_ATTRIBUTES
,
"file/directory exists after MsiSetTargetPath. Attributes: %08X
\n
"
,
r
);
r
=
MsiSetTargetPath
(
hpkg
,
"TARGETDIR"
,
tempdir
);
todo_wine
{
ok
(
r
==
ERROR_SUCCESS
,
"MsiSetTargetPath on subsubdir returned %d
\n
"
,
r
);
}
}
else
{
trace
(
"GetTempFileName failed, cannot do some tests
\n
"
);
}
...
...
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