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
c5c55210
Commit
c5c55210
authored
Nov 07, 2006
by
Mike McCormack
Committed by
Alexandre Julliard
Nov 07, 2006
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msi: Split ACTION_CostFinalize into two functions.
parent
97ee9c78
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
48 additions
and
40 deletions
+48
-40
action.c
dlls/msi/action.c
+48
-40
No files found.
dlls/msi/action.c
View file @
c5c55210
...
...
@@ -1939,48 +1939,10 @@ LPWSTR msi_get_disk_file_version( LPCWSTR filename )
return
strdupW
(
filever
);
}
/*
* A lot is done in this function aside from just the costing.
* The costing needs to be implemented at some point but for now I am going
* to focus on the directory building
*
*/
static
UINT
ACTION_CostFinalize
(
MSIPACKAGE
*
package
)
static
UINT
msi_check_file_install_states
(
MSIPACKAGE
*
package
)
{
static
const
WCHAR
ExecSeqQuery
[]
=
{
'S'
,
'E'
,
'L'
,
'E'
,
'C'
,
'T'
,
' '
,
'*'
,
' '
,
'F'
,
'R'
,
'O'
,
'M'
,
' '
,
'`'
,
'D'
,
'i'
,
'r'
,
'e'
,
'c'
,
't'
,
'o'
,
'r'
,
'y'
,
'`'
,
0
};
static
const
WCHAR
ConditionQuery
[]
=
{
'S'
,
'E'
,
'L'
,
'E'
,
'C'
,
'T'
,
' '
,
'*'
,
' '
,
'F'
,
'R'
,
'O'
,
'M'
,
' '
,
'`'
,
'C'
,
'o'
,
'n'
,
'd'
,
'i'
,
't'
,
'i'
,
'o'
,
'n'
,
'`'
,
0
};
static
const
WCHAR
szCosting
[]
=
{
'C'
,
'o'
,
's'
,
't'
,
'i'
,
'n'
,
'g'
,
'C'
,
'o'
,
'm'
,
'p'
,
'l'
,
'e'
,
't'
,
'e'
,
0
};
static
const
WCHAR
szlevel
[]
=
{
'I'
,
'N'
,
'S'
,
'T'
,
'A'
,
'L'
,
'L'
,
'L'
,
'E'
,
'V'
,
'E'
,
'L'
,
0
};
static
const
WCHAR
szOne
[]
=
{
'1'
,
0
};
MSICOMPONENT
*
comp
;
LPWSTR
file_version
;
MSIFILE
*
file
;
UINT
rc
;
MSIQUERY
*
view
;
LPWSTR
level
,
file_version
;
if
(
1
==
msi_get_property_int
(
package
,
szCosting
,
0
)
)
return
ERROR_SUCCESS
;
TRACE
(
"Building Directory properties
\n
"
);
rc
=
MSI_DatabaseOpenViewW
(
package
->
db
,
ExecSeqQuery
,
&
view
);
if
(
rc
==
ERROR_SUCCESS
)
{
rc
=
MSI_IterateRecords
(
view
,
NULL
,
ITERATE_CostFinalizeDirectories
,
package
);
msiobj_release
(
&
view
->
hdr
);
}
/* read components states from the registry */
ACTION_GetComponentInstallStates
(
package
);
TRACE
(
"File calculations
\n
"
);
LIST_FOR_EACH_ENTRY
(
file
,
&
package
->
files
,
MSIFILE
,
entry
)
{
...
...
@@ -2044,6 +2006,52 @@ static UINT ACTION_CostFinalize(MSIPACKAGE *package)
file
->
state
=
msifs_present
;
}
return
ERROR_SUCCESS
;
}
/*
* A lot is done in this function aside from just the costing.
* The costing needs to be implemented at some point but for now I am going
* to focus on the directory building
*
*/
static
UINT
ACTION_CostFinalize
(
MSIPACKAGE
*
package
)
{
static
const
WCHAR
ExecSeqQuery
[]
=
{
'S'
,
'E'
,
'L'
,
'E'
,
'C'
,
'T'
,
' '
,
'*'
,
' '
,
'F'
,
'R'
,
'O'
,
'M'
,
' '
,
'`'
,
'D'
,
'i'
,
'r'
,
'e'
,
'c'
,
't'
,
'o'
,
'r'
,
'y'
,
'`'
,
0
};
static
const
WCHAR
ConditionQuery
[]
=
{
'S'
,
'E'
,
'L'
,
'E'
,
'C'
,
'T'
,
' '
,
'*'
,
' '
,
'F'
,
'R'
,
'O'
,
'M'
,
' '
,
'`'
,
'C'
,
'o'
,
'n'
,
'd'
,
'i'
,
't'
,
'i'
,
'o'
,
'n'
,
'`'
,
0
};
static
const
WCHAR
szCosting
[]
=
{
'C'
,
'o'
,
's'
,
't'
,
'i'
,
'n'
,
'g'
,
'C'
,
'o'
,
'm'
,
'p'
,
'l'
,
'e'
,
't'
,
'e'
,
0
};
static
const
WCHAR
szlevel
[]
=
{
'I'
,
'N'
,
'S'
,
'T'
,
'A'
,
'L'
,
'L'
,
'L'
,
'E'
,
'V'
,
'E'
,
'L'
,
0
};
static
const
WCHAR
szOne
[]
=
{
'1'
,
0
};
MSICOMPONENT
*
comp
;
UINT
rc
;
MSIQUERY
*
view
;
LPWSTR
level
;
if
(
1
==
msi_get_property_int
(
package
,
szCosting
,
0
)
)
return
ERROR_SUCCESS
;
TRACE
(
"Building Directory properties
\n
"
);
rc
=
MSI_DatabaseOpenViewW
(
package
->
db
,
ExecSeqQuery
,
&
view
);
if
(
rc
==
ERROR_SUCCESS
)
{
rc
=
MSI_IterateRecords
(
view
,
NULL
,
ITERATE_CostFinalizeDirectories
,
package
);
msiobj_release
(
&
view
->
hdr
);
}
/* read components states from the registry */
ACTION_GetComponentInstallStates
(
package
);
TRACE
(
"File calculations
\n
"
);
msi_check_file_install_states
(
package
);
TRACE
(
"Evaluating Condition Table
\n
"
);
rc
=
MSI_DatabaseOpenViewW
(
package
->
db
,
ConditionQuery
,
&
view
);
...
...
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