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
582be6a7
Commit
582be6a7
authored
Jul 03, 2007
by
James Hawkins
Committed by
Alexandre Julliard
Jul 04, 2007
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msi: Handle remote calls to MsiGetSourcePath.
parent
b7479be1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
56 additions
and
3 deletions
+56
-3
install.c
dlls/msi/install.c
+47
-3
msiserver.idl
dlls/msi/msiserver.idl
+1
-0
package.c
dlls/msi/package.c
+8
-0
No files found.
dlls/msi/install.c
View file @
582be6a7
...
...
@@ -314,16 +314,60 @@ static UINT MSI_GetSourcePath( MSIHANDLE hInstall, LPCWSTR szFolder,
{
MSIPACKAGE
*
package
;
LPWSTR
path
;
UINT
r
;
UINT
r
=
ERROR_FUNCTION_FAILED
;
TRACE
(
"%s %p %p
\n
"
,
debugstr_w
(
szFolder
),
szPathBuf
,
pcchPathBuf
);
if
(
!
szFolder
)
return
ERROR_INVALID_PARAMETER
;
package
=
msihandle2msiinfo
(
hInstall
,
MSIHANDLETYPE_PACKAGE
);
package
=
msihandle2msiinfo
(
hInstall
,
MSIHANDLETYPE_PACKAGE
);
if
(
!
package
)
return
ERROR_INVALID_HANDLE
;
{
HRESULT
hr
;
IWineMsiRemotePackage
*
remote_package
;
LPWSTR
value
=
NULL
;
DWORD
len
;
remote_package
=
(
IWineMsiRemotePackage
*
)
msi_get_remote
(
hInstall
);
if
(
!
remote_package
)
return
ERROR_INVALID_HANDLE
;
len
=
0
;
hr
=
IWineMsiRemotePackage_GetSourcePath
(
remote_package
,
(
BSTR
*
)
szFolder
,
NULL
,
&
len
);
if
(
FAILED
(
hr
))
goto
done
;
len
++
;
value
=
msi_alloc
(
len
*
sizeof
(
WCHAR
));
if
(
!
value
)
{
r
=
ERROR_OUTOFMEMORY
;
goto
done
;
}
hr
=
IWineMsiRemotePackage_GetSourcePath
(
remote_package
,
(
BSTR
*
)
szFolder
,
(
BSTR
*
)
value
,
&
len
);
if
(
FAILED
(
hr
))
goto
done
;
r
=
msi_strcpy_to_awstring
(
value
,
szPathBuf
,
pcchPathBuf
);
done:
IWineMsiRemotePackage_Release
(
remote_package
);
msi_free
(
value
);
if
(
FAILED
(
hr
))
{
if
(
HRESULT_FACILITY
(
hr
)
==
FACILITY_WIN32
)
return
HRESULT_CODE
(
hr
);
return
ERROR_FUNCTION_FAILED
;
}
return
r
;
}
if
(
szPathBuf
->
str
.
w
&&
!
pcchPathBuf
)
{
...
...
dlls/msi/msiserver.idl
View file @
582be6a7
...
...
@@ -43,6 +43,7 @@ interface IWineMsiRemotePackage : IUnknown
HRESULT
DoAction
(
[
in
]
BSTR
*
action
)
;
HRESULT
Sequence
(
[
in
]
BSTR
*
table
,
[
in
]
int
sequence
)
;
HRESULT
GetTargetPath
(
[
in
]
BSTR
*
folder
,
[
out
]
BSTR
*
value
,
[
out
]
DWORD
*
size
)
;
HRESULT
GetSourcePath
(
[
in
]
BSTR
*
folder
,
[
out
]
BSTR
*
value
,
[
out
]
DWORD
*
size
)
;
}
[
...
...
dlls/msi/package.c
View file @
582be6a7
...
...
@@ -1597,6 +1597,13 @@ HRESULT WINAPI mrp_GetTargetPath( IWineMsiRemotePackage *iface, BSTR *folder, BS
return
HRESULT_FROM_WIN32
(
r
);
}
HRESULT
WINAPI
mrp_GetSourcePath
(
IWineMsiRemotePackage
*
iface
,
BSTR
*
folder
,
BSTR
*
value
,
DWORD
*
size
)
{
msi_remote_package_impl
*
This
=
mrp_from_IWineMsiRemotePackage
(
iface
);
UINT
r
=
MsiGetSourcePathW
(
This
->
package
,
(
LPWSTR
)
folder
,
(
LPWSTR
)
value
,
size
);
return
HRESULT_FROM_WIN32
(
r
);
}
static
const
IWineMsiRemotePackageVtbl
msi_remote_package_vtbl
=
{
mrp_QueryInterface
,
...
...
@@ -1610,6 +1617,7 @@ static const IWineMsiRemotePackageVtbl msi_remote_package_vtbl =
mrp_DoAction
,
mrp_Sequence
,
mrp_GetTargetPath
,
mrp_GetSourcePath
,
};
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