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
6b97f890
Commit
6b97f890
authored
Jul 05, 2007
by
James Hawkins
Committed by
Alexandre Julliard
Jul 06, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msi: Handle remote calls to MsiEvaluateCondition.
parent
ba491991
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
50 additions
and
5 deletions
+50
-5
cond.y
dlls/msi/cond.y
+41
-5
msiserver.idl
dlls/msi/msiserver.idl
+1
-0
package.c
dlls/msi/package.c
+8
-0
No files found.
dlls/msi/cond.y
View file @
6b97f890
...
...
@@ -20,6 +20,8 @@
*
Foundation
,
Inc
.,
51
Franklin
St
,
Fifth
Floor
,
Boston
,
MA
02110
-
1301
,
USA
*/
#
define
COBJMACROS
#
include
"config.h"
#
include
<
stdarg
.
h
>
...
...
@@ -29,12 +31,15 @@
#
include
"windef.h"
#
include
"winbase.h"
#
include
"winuser.h"
#
include
"wine/debug.h"
#
include
"wine/unicode.h"
#
include
"msi.h"
#
include
"msiquery.h"
#
include
"objbase.h"
#
include
"oleauto.h"
#
include
"msipriv.h"
#
include
"msiserver.h"
#
include
"wine/debug.h"
#
include
"wine/unicode.h"
#
define
YYLEX_PARAM
info
#
define
YYPARSE_PARAM
info
...
...
@@ -742,8 +747,39 @@ MSICONDITION WINAPI MsiEvaluateConditionW( MSIHANDLE hInstall, LPCWSTR szConditi
UINT
ret
;
package
=
msihandle2msiinfo
(
hInstall
,
MSIHANDLETYPE_PACKAGE
);
if
(
!package)
return
MSICONDITION_ERROR
;
if
(
!package )
{
HRESULT
hr
;
BSTR
condition
;
IWineMsiRemotePackage
*
remote_package
;
remote_package
=
(
IWineMsiRemotePackage
*)
msi_get_remote
(
hInstall
);
if
(
!remote_package)
return
MSICONDITION_ERROR
;
condition
=
SysAllocString
(
szCondition
);
if
(
!condition)
{
IWineMsiRemotePackage_Release
(
remote_package
);
return
ERROR_OUTOFMEMORY
;
}
hr
=
IWineMsiRemotePackage_EvaluateCondition
(
remote_package
,
condition
);
SysFreeString
(
condition
);
IWineMsiRemotePackage_Release
(
remote_package
);
if
(
FAILED
(
hr
))
{
if
(
HRESULT_FACILITY
(
hr
)
==
FACILITY_WIN32
)
return
HRESULT_CODE
(
hr
);
return
ERROR_FUNCTION_FAILED
;
}
return
ERROR_SUCCESS
;
}
ret
=
MSI_EvaluateConditionW
(
package
,
szCondition
);
msiobj_release
(
&
package
->
hdr
);
return
ret
;
...
...
dlls/msi/msiserver.idl
View file @
6b97f890
...
...
@@ -56,6 +56,7 @@ interface IWineMsiRemotePackage : IUnknown
HRESULT
GetLanguage
(
[
out
]
LANGID
*
language
)
;
HRESULT
SetInstallLevel
(
[
in
]
int
level
)
;
HRESULT
FormatRecord
(
[
in
]
MSIHANDLE
record
,
[
out
]
BSTR
value
,
[
out
]
DWORD
*
size
)
;
HRESULT
EvaluateCondition
(
[
in
]
BSTR
condition
)
;
}
[
...
...
dlls/msi/package.c
View file @
6b97f890
...
...
@@ -1692,6 +1692,13 @@ HRESULT WINAPI mrp_FormatRecord( IWineMsiRemotePackage *iface, MSIHANDLE record,
return
HRESULT_FROM_WIN32
(
r
);
}
HRESULT
WINAPI
mrp_EvaluateCondition
(
IWineMsiRemotePackage
*
iface
,
BSTR
condition
)
{
msi_remote_package_impl
*
This
=
mrp_from_IWineMsiRemotePackage
(
iface
);
UINT
r
=
MsiEvaluateConditionW
(
This
->
package
,
(
LPWSTR
)
condition
);
return
HRESULT_FROM_WIN32
(
r
);
}
static
const
IWineMsiRemotePackageVtbl
msi_remote_package_vtbl
=
{
mrp_QueryInterface
,
...
...
@@ -1715,6 +1722,7 @@ static const IWineMsiRemotePackageVtbl msi_remote_package_vtbl =
mrp_GetLanguage
,
mrp_SetInstallLevel
,
mrp_FormatRecord
,
mrp_EvaluateCondition
,
};
HRESULT
create_msi_remote_package
(
IUnknown
*
pOuter
,
LPVOID
*
ppObj
)
...
...
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