Mike McCormack : msi: Cleanup traces, remove unnecessary includes.
Alexandre Julliard
julliard at wine.codeweavers.com
Mon Jul 17 08:14:46 CDT 2006
Module: wine
Branch: refs/heads/master
Commit: 741b47fd2678c8b0ee8f4d4e22b6a05dfbb23ec4
URL: http://source.winehq.org/git/?p=wine.git;a=commit;h=741b47fd2678c8b0ee8f4d4e22b6a05dfbb23ec4
Author: Mike McCormack <mike at codeweavers.com>
Date: Sat Jul 15 13:56:09 2006 +0900
msi: Cleanup traces, remove unnecessary includes.
---
dlls/msi/install.c | 26 +++++++++-----------------
1 files changed, 9 insertions(+), 17 deletions(-)
diff --git a/dlls/msi/install.c b/dlls/msi/install.c
index a09782d..8724c95 100644
--- a/dlls/msi/install.c
+++ b/dlls/msi/install.c
@@ -29,8 +29,6 @@ #include "wine/debug.h"
#include "msi.h"
#include "msidefs.h"
#include "msipriv.h"
-#include "winuser.h"
-#include "wine/unicode.h"
#include "action.h"
WINE_DEFAULT_DEBUG_CHANNEL(msi);
@@ -333,19 +331,19 @@ UINT MSI_SetTargetPathW(MSIPACKAGE *pack
MSIFOLDER *folder;
MSIFILE *file;
- TRACE("(%p %s %s)\n",package, debugstr_w(szFolder),debugstr_w(szFolderPath));
+ TRACE("%p %s %s\n",package, debugstr_w(szFolder),debugstr_w(szFolderPath));
attrib = GetFileAttributesW(szFolderPath);
+ /* native MSI tests writeability by making temporary files at each drive */
if ( attrib != INVALID_FILE_ATTRIBUTES &&
(attrib & FILE_ATTRIBUTE_OFFLINE ||
- attrib & FILE_ATTRIBUTE_READONLY)) /* actually native MSI tests writeability by making temporary files at each drive */
+ attrib & FILE_ATTRIBUTE_READONLY))
return ERROR_FUNCTION_FAILED;
path = resolve_folder(package,szFolder,FALSE,FALSE,&folder);
if (!path)
return ERROR_DIRECTORY;
-
msi_free(folder->Property);
folder->Property = build_directory_name(2, szFolderPath, NULL);
@@ -405,7 +403,7 @@ UINT WINAPI MsiSetTargetPathW(MSIHANDLE
MSIPACKAGE *package;
UINT ret;
- TRACE("(%s %s)\n",debugstr_w(szFolder),debugstr_w(szFolderPath));
+ TRACE("%s %s\n",debugstr_w(szFolder),debugstr_w(szFolderPath));
if ( !szFolder || !szFolderPath )
return ERROR_INVALID_PARAMETER;
@@ -452,7 +450,6 @@ UINT WINAPI MsiSetTargetPathW(MSIHANDLE
* Not in the state: FALSE
*
*/
-
BOOL WINAPI MsiGetMode(MSIHANDLE hInstall, MSIRUNMODE iRunMode)
{
BOOL r = FALSE;
@@ -532,7 +529,7 @@ UINT WINAPI MSI_SetFeatureStateW(MSIPACK
UINT rc = ERROR_SUCCESS;
MSIFEATURE *feature, *child;
- TRACE(" %s to %i\n",debugstr_w(szFeature), iState);
+ TRACE("%s %i\n", debugstr_w(szFeature), iState);
feature = get_loaded_feature(package,szFeature);
if (!feature)
@@ -566,7 +563,7 @@ UINT WINAPI MsiSetFeatureStateW(MSIHANDL
MSIPACKAGE* package;
UINT rc = ERROR_SUCCESS;
- TRACE(" %s to %i\n",debugstr_w(szFeature), iState);
+ TRACE("%s %i\n",debugstr_w(szFeature), iState);
package = msihandle2msiinfo(hInstall, MSIHANDLETYPE_PACKAGE);
if (!package)
@@ -625,8 +622,7 @@ UINT WINAPI MsiGetFeatureStateW(MSIHANDL
MSIPACKAGE* package;
UINT ret;
- TRACE("%ld %s %p %p\n", hInstall, debugstr_w(szFeature), piInstalled,
-piAction);
+ TRACE("%ld %s %p %p\n", hInstall, debugstr_w(szFeature), piInstalled, piAction);
package = msihandle2msiinfo(hInstall, MSIHANDLETYPE_PACKAGE);
if (!package)
@@ -753,7 +749,6 @@ LANGID WINAPI MsiGetLanguage(MSIHANDLE h
{
MSIPACKAGE* package;
LANGID langid;
- LPWSTR buffer;
static const WCHAR szProductLanguage[] =
{'P','r','o','d','u','c','t','L','a','n','g','u','a','g','e',0};
@@ -761,10 +756,7 @@ LANGID WINAPI MsiGetLanguage(MSIHANDLE h
if (!package)
return ERROR_INVALID_HANDLE;
- buffer = msi_dup_property( package, szProductLanguage );
- langid = atoiW(buffer);
-
- msi_free(buffer);
- msiobj_release (&package->hdr);
+ langid = msi_get_property_int( package, szProductLanguage, 0 );
+ msiobj_release( &package->hdr );
return langid;
}
More information about the wine-cvs
mailing list