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
32f57022
Commit
32f57022
authored
Sep 20, 2006
by
James Hawkins
Committed by
Alexandre Julliard
Sep 21, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msi: Don't check a component's install state if a component ID is not provided.
parent
6ac0f3ed
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
36 additions
and
59 deletions
+36
-59
action.c
dlls/msi/action.c
+18
-2
package.c
dlls/msi/tests/package.c
+18
-57
No files found.
dlls/msi/action.c
View file @
32f57022
...
...
@@ -1522,9 +1522,16 @@ static void ACTION_UpdateInstallStates(MSIPACKAGE *package)
MSICOMPONENT
*
comp
;
MSIFEATURE
*
feature
;
/* FIXME: component's installed state should be determined
* by the component's registration
*/
LIST_FOR_EACH_ENTRY
(
comp
,
&
package
->
components
,
MSICOMPONENT
,
entry
)
{
INSTALLSTATE
res
;
if
(
!
comp
->
ComponentId
)
continue
;
res
=
MsiGetComponentPathW
(
package
->
ProductCode
,
comp
->
ComponentId
,
NULL
,
NULL
);
if
(
res
<
0
)
...
...
@@ -1541,6 +1548,12 @@ static void ACTION_UpdateInstallStates(MSIPACKAGE *package)
{
comp
=
cl
->
component
;
if
(
!
comp
->
ComponentId
)
{
res
=
INSTALLSTATE_ABSENT
;
break
;
}
if
(
res
==
-
10
)
res
=
comp
->
Installed
;
else
...
...
@@ -1548,8 +1561,11 @@ static void ACTION_UpdateInstallStates(MSIPACKAGE *package)
if
(
res
==
comp
->
Installed
)
continue
;
if
(
res
!=
comp
->
Installed
)
res
=
INSTALLSTATE_INCOMPLETE
;
if
(
res
!=
INSTALLSTATE_DEFAULT
||
res
!=
INSTALLSTATE_LOCAL
||
res
!=
INSTALLSTATE_SOURCE
)
{
res
=
INSTALLSTATE_INCOMPLETE
;
}
}
}
feature
->
Installed
=
res
;
...
...
dlls/msi/tests/package.c
View file @
32f57022
...
...
@@ -2510,90 +2510,63 @@ static void test_featureparents(void)
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"leo"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_LOCAL
,
"Expected INSTALLSTATE_LOCAL, got %d
\n
"
,
action
);
state
=
0xdeadbee
;
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"virgo"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_SOURCE
,
"Expected INSTALLSTATE_SOURCE, got %d
\n
"
,
action
);
state
=
0xdeadbee
;
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"libra"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_LOCAL
,
"Expected INSTALLSTATE_LOCAL, got %d
\n
"
,
action
);
state
=
0xdeadbee
;
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"cassiopeia"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_LOCAL
,
"Expected INSTALLSTATE_LOCAL, got %d
\n
"
,
action
);
state
=
0xdeadbee
;
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"cepheus"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_SOURCE
,
"Expected INSTALLSTATE_SOURCE, got %d
\n
"
,
action
);
state
=
0xdeadbee
;
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"andromeda"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_LOCAL
,
"Expected INSTALLSTATE_LOCAL, got %d
\n
"
,
action
);
state
=
0xdeadbee
;
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"canis"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_LOCAL
,
"Expected INSTALLSTATE_LOCAL, got %d
\n
"
,
action
);
state
=
0xdeadbee
;
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"monoceros"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_SOURCE
,
"Expected INSTALLSTATE_SOURCE, got %d
\n
"
,
action
);
state
=
0xdeadbee
;
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"lepus"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_LOCAL
,
"Expected INSTALLSTATE_LOCAL, got %d
\n
"
,
action
);
r
=
MsiSetFeatureState
(
hpkg
,
"orion"
,
INSTALLSTATE_ABSENT
);
...
...
@@ -2624,19 +2597,16 @@ static void test_featureparents(void)
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"leo"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_LOCAL
,
"Expected INSTALLSTATE_LOCAL, got %d
\n
"
,
action
);
state
=
0xdeadbee
;
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"virgo"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_SOURCE
,
"Expected INSTALLSTATE_SOURCE, got %d
\n
"
,
action
);
}
...
...
@@ -2644,19 +2614,16 @@ static void test_featureparents(void)
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"libra"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_LOCAL
,
"Expected INSTALLSTATE_LOCAL, got %d
\n
"
,
action
);
state
=
0xdeadbee
;
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"cassiopeia"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_LOCAL
,
"Expected INSTALLSTATE_LOCAL, got %d
\n
"
,
action
);
}
...
...
@@ -2664,29 +2631,23 @@ static void test_featureparents(void)
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"cepheus"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_SOURCE
,
"Expected INSTALLSTATE_SOURCE, got %d
\n
"
,
action
);
state
=
0xdeadbee
;
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"andromeda"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
}
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_SOURCE
,
"Expected INSTALLSTATE_SOURCE, got %d
\n
"
,
action
);
state
=
0xdeadbee
;
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"canis"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
action
);
}
...
...
@@ -2694,9 +2655,9 @@ static void test_featureparents(void)
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"monoceros"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
action
);
}
...
...
@@ -2704,9 +2665,9 @@ static void test_featureparents(void)
action
=
0xdeadbee
;
r
=
MsiGetComponentState
(
hpkg
,
"lepus"
,
&
state
,
&
action
);
ok
(
r
==
ERROR_SUCCESS
,
"Expected ERROR_SUCCESS, got %d
\n
"
,
r
);
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
todo_wine
{
ok
(
state
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
state
);
ok
(
action
==
INSTALLSTATE_UNKNOWN
,
"Expected INSTALLSTATE_UNKNOWN, got %d
\n
"
,
action
);
}
...
...
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