Commit c3135c63 authored by Hans Leidekker's avatar Hans Leidekker Committed by Alexandre Julliard

msi: Build without -DWINE_NO_LONG_TYPES.

parent 337d7911
EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = msi.dll
IMPORTLIB = msi
IMPORTS = uuid urlmon wininet comctl32 shell32 shlwapi cabinet oleaut32 ole32 version user32 gdi32 advapi32 rpcrt4 sxs imagehlp mspatcha odbccp32 wintrust crypt32
......
......@@ -139,7 +139,7 @@ static UINT get_signature( MSIPACKAGE *package, MSISIGNATURE *sig, const WCHAR *
TRACE("MaxVersion is %d.%d.%d.%d\n", HIWORD(sig->MaxVersionMS),
LOWORD(sig->MaxVersionMS), HIWORD(sig->MaxVersionLS),
LOWORD(sig->MaxVersionLS));
TRACE("MinSize is %d, MaxSize is %d;\n", sig->MinSize, sig->MaxSize);
TRACE("MinSize is %lu, MaxSize is %lu\n", sig->MinSize, sig->MaxSize);
TRACE("Languages is %s\n", debugstr_w(sig->Languages));
msiobj_release( &row->hdr );
......@@ -336,7 +336,7 @@ static void convert_reg_value( DWORD regType, const BYTE *value, DWORD sz, WCHAR
swprintf(ptr, 3, L"%02X", value[i]);
break;
default:
WARN("unimplemented for values of type %d\n", regType);
WARN( "unimplemented for values of type %lu\n", regType );
*appValue = NULL;
}
}
......
......@@ -233,7 +233,7 @@ static BOOL is_assembly_installed( IAssemblyCache *cache, const WCHAR *display_n
{
return (info.dwAssemblyFlags == ASSEMBLYINFO_FLAG_INSTALLED);
}
TRACE("QueryAssemblyInfo returned 0x%08x\n", hr);
TRACE( "QueryAssemblyInfo returned %#lx\n", hr );
return FALSE;
}
......@@ -337,7 +337,7 @@ MSIASSEMBLY *msi_load_assembly( MSIPACKAGE *package, MSICOMPONENT *comp )
TRACE("application %s\n", debugstr_w(a->application));
a->attributes = MSI_RecordGetInteger( rec, 5 );
TRACE("attributes %u\n", a->attributes);
TRACE( "attributes %lu\n", a->attributes );
if (!(a->display_name = get_assembly_display_name( package->db, comp->Component, a )))
{
......@@ -445,7 +445,7 @@ UINT msi_install_assembly( MSIPACKAGE *package, MSICOMPONENT *comp )
hr = IAssemblyCache_InstallAssembly( cache, 0, manifest, NULL );
if (hr != S_OK)
{
ERR("Failed to install assembly %s (0x%08x)\n", debugstr_w(manifest), hr);
ERR( "failed to install assembly %s (%#lx)\n", debugstr_w(manifest), hr );
return ERROR_FUNCTION_FAILED;
}
if (feature) feature->Action = INSTALLSTATE_LOCAL;
......@@ -474,7 +474,7 @@ UINT msi_uninstall_assembly( MSIPACKAGE *package, MSICOMPONENT *comp )
{
cache = package->cache_sxs;
hr = IAssemblyCache_UninstallAssembly( cache, 0, assembly->display_name, NULL, NULL );
if (FAILED( hr )) WARN("failed to uninstall assembly 0x%08x\n", hr);
if (FAILED( hr )) WARN( "failed to uninstall assembly %#lx\n", hr );
}
else
{
......@@ -486,7 +486,7 @@ UINT msi_uninstall_assembly( MSIPACKAGE *package, MSICOMPONENT *comp )
if (cache)
{
hr = IAssemblyCache_UninstallAssembly( cache, 0, assembly->display_name, NULL, NULL );
if (FAILED( hr )) WARN("failed to uninstall assembly 0x%08x\n", hr);
if (FAILED( hr )) WARN( "failed to uninstall assembly %#lx\n", hr );
}
}
}
......@@ -638,7 +638,7 @@ UINT ACTION_MsiPublishAssemblies( MSIPACKAGE *package )
}
if ((res = open_local_assembly_key( package->Context, win32, file->TargetPath, &hkey )))
{
WARN("failed to open local assembly key %d\n", res);
WARN( "failed to open local assembly key %ld\n", res );
return ERROR_FUNCTION_FAILED;
}
}
......@@ -646,14 +646,14 @@ UINT ACTION_MsiPublishAssemblies( MSIPACKAGE *package )
{
if ((res = open_global_assembly_key( package->Context, win32, &hkey )))
{
WARN("failed to open global assembly key %d\n", res);
WARN( "failed to open global assembly key %ld\n", res );
return ERROR_FUNCTION_FAILED;
}
}
size = sizeof(buffer);
if ((res = RegSetValueExW( hkey, assembly->display_name, 0, REG_MULTI_SZ, (const BYTE *)buffer, size )))
{
WARN("failed to set assembly value %d\n", res);
WARN( "failed to set assembly value %ld\n", res );
}
RegCloseKey( hkey );
......@@ -699,17 +699,17 @@ UINT ACTION_MsiUnpublishAssemblies( MSIPACKAGE *package )
continue;
}
if ((res = delete_local_assembly_key( package->Context, win32, file->TargetPath )))
WARN("failed to delete local assembly key %d\n", res);
WARN( "failed to delete local assembly key %ld\n", res );
}
else
{
HKEY hkey;
if ((res = open_global_assembly_key( package->Context, win32, &hkey )))
WARN("failed to delete global assembly key %d\n", res);
WARN( "failed to delete global assembly key %ld\n", res );
else
{
if ((res = RegDeleteValueW( hkey, assembly->display_name )))
WARN("failed to delete global assembly value %d\n", res);
WARN( "failed to delete global assembly value %ld\n", res );
RegCloseKey( hkey );
}
}
......
......@@ -265,7 +265,7 @@ static HRESULT WINAPI AutomationObject_GetTypeInfo(
AutomationObject *This = impl_from_IDispatch(iface);
HRESULT hr;
TRACE("(%p/%p)->(%d,%d,%p)\n", iface, This, iTInfo, lcid, ppTInfo);
TRACE( "(%p/%p)->(%u, %ld, %p)\n", iface, This, iTInfo, lcid, ppTInfo );
hr = get_typeinfo(This->tid, ppTInfo);
if (FAILED(hr))
......@@ -287,7 +287,7 @@ static HRESULT WINAPI AutomationObject_GetIDsOfNames(
ITypeInfo *ti;
HRESULT hr;
TRACE("(%p/%p)->(%s, %p, %d, %d, %p)\n", iface, This,
TRACE("(%p/%p)->(%s, %p, %u, %ld, %p)\n", iface, This,
debugstr_guid(riid), rgszNames, cNames, lcid, rgDispId);
if (!IsEqualGUID(riid, &IID_NULL)) return E_INVALIDARG;
......@@ -331,7 +331,7 @@ static HRESULT WINAPI AutomationObject_Invoke(
BSTR bstrName = NULL;
ITypeInfo *ti;
TRACE("(%p/%p)->(%d, %s, %d, %d, %p, %p, %p, %p)\n", iface, This,
TRACE("(%p/%p)->(%ld, %s, %ld, %d, %p, %p, %p, %p)\n", iface, This,
dispIdMember, debugstr_guid(riid), lcid, wFlags,
pDispParams, pVarResult, pExcepInfo, puArgErr);
......@@ -362,14 +362,14 @@ static HRESULT WINAPI AutomationObject_Invoke(
if (TRACE_ON(msi))
{
ITypeInfo_GetDocumentation(ti, dispIdMember, &bstrName, NULL, NULL, NULL);
TRACE("Method %d, %s\n", dispIdMember, debugstr_w(bstrName));
TRACE("method %ld, %s\n", dispIdMember, debugstr_w(bstrName));
}
hr = tid_ids[This->tid].fn_invoke(This,dispIdMember,riid,lcid,wFlags,pDispParams,pVarResult,pExcepInfo,puArgErr);
if (hr == DISP_E_MEMBERNOTFOUND) {
if (bstrName == NULL) ITypeInfo_GetDocumentation(ti, dispIdMember, &bstrName, NULL, NULL, NULL);
FIXME("Method %d, %s wflags %d not implemented, clsid %s\n", dispIdMember, debugstr_w(bstrName), wFlags,
FIXME("method %ld, %s wflags %d not implemented, clsid %s\n", dispIdMember, debugstr_w(bstrName), wFlags,
debugstr_guid(get_riid_from_tid(This->tid)));
}
else if (pExcepInfo &&
......@@ -383,7 +383,7 @@ static HRESULT WINAPI AutomationObject_Invoke(
if (FAILED(ITypeInfo_GetNames(ti, dispIdMember, bstrParamNames,
MAX_FUNC_PARAMS, &namesNo)))
{
TRACE("Failed to retrieve names for dispIdMember %d\n", dispIdMember);
TRACE("failed to retrieve names for dispIdMember %ld\n", dispIdMember);
}
else
{
......@@ -412,7 +412,7 @@ static HRESULT WINAPI AutomationObject_Invoke(
/* Free function name if we retrieved it */
SysFreeString(bstrName);
TRACE("Returning 0x%08x, %s\n", hr, SUCCEEDED(hr) ? "ok" : "not ok");
TRACE("returning %#lx, %s\n", hr, SUCCEEDED(hr) ? "ok" : "not ok");
return hr;
}
......@@ -470,7 +470,7 @@ static HRESULT WINAPI ProvideMultipleClassInfo_GetClassInfo(IProvideMultipleClas
static HRESULT WINAPI ProvideMultipleClassInfo_GetGUID(IProvideMultipleClassInfo* iface, DWORD dwGuidKind, GUID* pGUID)
{
AutomationObject *This = impl_from_IProvideMultipleClassInfo(iface);
TRACE("(%p/%p)->(%d,%s)\n", iface, This, dwGuidKind, debugstr_guid(pGUID));
TRACE("(%p/%p)->(%lu, %s)\n", iface, This, dwGuidKind, debugstr_guid(pGUID));
if (dwGuidKind != GUIDKIND_DEFAULT_SOURCE_DISP_IID)
return E_INVALIDARG;
......@@ -500,7 +500,8 @@ static HRESULT WINAPI ProvideMultipleClassInfo_GetInfoOfIndex(IProvideMultipleCl
{
AutomationObject *This = impl_from_IProvideMultipleClassInfo(iface);
TRACE("(%p/%p)->(%d,%d,%p,%p,%p,%p,%p)\n", iface, This, iti, dwFlags, ti, pdwTIFlags, pcdispidReserved, piidPrimary, piidSource);
TRACE("(%p/%p)->(%lu, %#lx, %p, %p, %p, %p, %p)\n", iface, This, iti, dwFlags, ti, pdwTIFlags, pcdispidReserved,
piidPrimary, piidSource);
if (iti != 0)
return E_INVALIDARG;
......@@ -542,7 +543,7 @@ static const IProvideMultipleClassInfoVtbl ProvideMultipleClassInfoVtbl =
static void init_automation_object(AutomationObject *This, MSIHANDLE msiHandle, tid_t tid)
{
TRACE("(%p, %d, %s)\n", This, msiHandle, debugstr_guid(get_riid_from_tid(tid)));
TRACE("%p, %lu, %s\n", This, msiHandle, debugstr_guid(get_riid_from_tid(tid)));
This->IDispatch_iface.lpVtbl = &AutomationObjectVtbl;
This->IProvideMultipleClassInfo_iface.lpVtbl = &ProvideMultipleClassInfoVtbl;
......@@ -618,7 +619,7 @@ static HRESULT WINAPI ListEnumerator_Next(IEnumVARIANT* iface, ULONG celt, VARIA
ListEnumerator *This = impl_from_IEnumVARIANT(iface);
ULONG i, local;
TRACE("(%p, %uld, %p, %p)\n", iface, celt, rgVar, fetched);
TRACE("%p, %lu, %p, %p\n", iface, celt, rgVar, fetched);
if (fetched) *fetched = 0;
......@@ -641,7 +642,7 @@ static HRESULT WINAPI ListEnumerator_Skip(IEnumVARIANT* iface, ULONG celt)
{
ListEnumerator *This = impl_from_IEnumVARIANT(iface);
TRACE("(%p,%uld)\n", iface, celt);
TRACE("%p, %lu\n", iface, celt);
This->pos += celt;
if (This->pos >= This->list->count)
......@@ -1030,7 +1031,7 @@ static HRESULT list_invoke(
if (SUCCEEDED(hr = create_list_enumerator(list, (LPVOID *)&pUnk)))
V_UNKNOWN(pVarResult) = pUnk;
else
ERR("Failed to create IEnumVARIANT object, hresult 0x%08x\n", hr);
ERR("failed to create IEnumVARIANT object, hresult %#lx\n", hr);
}
else return DISP_E_MEMBERNOTFOUND;
break;
......@@ -1189,7 +1190,7 @@ static HRESULT view_invoke(
if ((ret = MsiViewFetch(This->msiHandle, &msiHandle)) == ERROR_SUCCESS)
{
if (FAILED(hr = create_record(msiHandle, &V_DISPATCH(pVarResult))))
ERR("Failed to create Record object, hresult 0x%08x\n", hr);
ERR("failed to create Record object, hresult %#lx\n", hr);
}
else if (ret == ERROR_NO_MORE_ITEMS)
V_DISPATCH(pVarResult) = NULL;
......@@ -1289,7 +1290,7 @@ HRESULT database_invoke(
if (SUCCEEDED(hr))
V_DISPATCH(pVarResult) = dispatch;
else
ERR("Failed to create SummaryInfo object: 0x%08x\n", hr);
ERR("failed to create SummaryInfo object: %#lx\n", hr);
}
else
{
......@@ -1311,7 +1312,7 @@ HRESULT database_invoke(
if (SUCCEEDED(hr = create_view(msiHandle, &dispatch)))
V_DISPATCH(pVarResult) = dispatch;
else
ERR("Failed to create View object, hresult 0x%08x\n", hr);
ERR("failed to create View object, hresult %#lx\n", hr);
}
else
{
......@@ -1447,7 +1448,7 @@ static HRESULT session_invoke(
if (SUCCEEDED(hr = create_database(msiHandle, &dispatch)))
V_DISPATCH(pVarResult) = dispatch;
else
ERR("Failed to create Database object, hresult 0x%08x\n", hr);
ERR("failed to create Database object, hresult %#lx\n", hr);
}
else
{
......@@ -1617,11 +1618,11 @@ static void variant_from_registry_value(VARIANT *pVarResult, DWORD dwType, LPBYT
case REG_EXPAND_SZ:
if (!(dwNewSize = ExpandEnvironmentStringsW(szString, szNewString, dwNewSize)))
ERR("ExpandEnvironmentStrings returned error %d\n", GetLastError());
ERR("ExpandEnvironmentStrings returned error %lu\n", GetLastError());
else if (!(szNewString = msi_alloc(dwNewSize * sizeof(WCHAR))))
ERR("Out of memory\n");
else if (!(dwNewSize = ExpandEnvironmentStringsW(szString, szNewString, dwNewSize)))
ERR("ExpandEnvironmentStrings returned error %d\n", GetLastError());
ERR("ExpandEnvironmentStrings returned error %lu\n", GetLastError());
else
{
V_VT(pVarResult) = VT_BSTR;
......@@ -1650,7 +1651,7 @@ static void variant_from_registry_value(VARIANT *pVarResult, DWORD dwType, LPBYT
break;
default:
FIXME("Unhandled registry value type %d\n", dwType);
FIXME("Unhandled registry value type %lu\n", dwType);
}
}
......@@ -2455,7 +2456,7 @@ static HRESULT create_database(MSIHANDLE msiHandle, IDispatch **dispatch)
{
AutomationObject *database;
TRACE("(%d %p)\n", msiHandle, dispatch);
TRACE("%lu %p\n", msiHandle, dispatch);
database = msi_alloc(sizeof(AutomationObject));
if (!database) return E_OUTOFMEMORY;
......@@ -2471,7 +2472,7 @@ static HRESULT create_view(MSIHANDLE msiHandle, IDispatch **dispatch)
{
AutomationObject *view;
TRACE("(%d %p)\n", msiHandle, dispatch);
TRACE("%lu %p\n", msiHandle, dispatch);
view = msi_alloc(sizeof(AutomationObject));
if (!view) return E_OUTOFMEMORY;
......
......@@ -911,7 +911,7 @@ UINT ACTION_UnregisterClassInfo( MSIPACKAGE *package )
res = RegDeleteTreeW( hkey, cls->clsid );
if (res != ERROR_SUCCESS)
WARN("Failed to delete class key %d\n", res);
WARN("failed to delete class key %ld\n", res);
if (cls->AppID)
{
......@@ -920,7 +920,7 @@ UINT ACTION_UnregisterClassInfo( MSIPACKAGE *package )
{
res = RegDeleteKeyW( hkey2, cls->AppID->AppID );
if (res != ERROR_SUCCESS)
WARN("Failed to delete appid key %d\n", res);
WARN("failed to delete appid key %ld\n", res);
RegCloseKey( hkey2 );
}
}
......@@ -935,7 +935,7 @@ UINT ACTION_UnregisterClassInfo( MSIPACKAGE *package )
msi_free( filetype );
if (res != ERROR_SUCCESS)
WARN("Failed to delete file type %d\n", res);
WARN("failed to delete file type %ld\n", res);
}
}
......@@ -1111,7 +1111,7 @@ UINT ACTION_UnregisterProgIdInfo( MSIPACKAGE *package )
res = RegDeleteTreeW( HKEY_CLASSES_ROOT, progid->ProgID );
if (res != ERROR_SUCCESS)
TRACE("Failed to delete progid key %d\n", res);
TRACE("failed to delete progid key %ld\n", res);
uirow = MSI_CreateRecord( 1 );
MSI_RecordSetStringW( uirow, 1, progid->ProgID );
......@@ -1256,7 +1256,7 @@ UINT ACTION_RegisterExtensionInfo(MSIPACKAGE *package)
res = RegCreateKeyW( HKEY_CLASSES_ROOT, extension, &hkey );
msi_free( extension );
if (res != ERROR_SUCCESS)
WARN("Failed to create extension key %d\n", res);
WARN("failed to create extension key %ld\n", res);
}
if (ext->Mime)
......@@ -1355,7 +1355,7 @@ UINT ACTION_UnregisterExtensionInfo( MSIPACKAGE *package )
res = RegDeleteTreeW( HKEY_CLASSES_ROOT, extension );
msi_free( extension );
if (res != ERROR_SUCCESS)
WARN("Failed to delete extension key %d\n", res);
WARN("failed to delete extension key %ld\n", res);
}
if (ext->ProgID || ext->ProgIDText)
......@@ -1376,7 +1376,7 @@ UINT ACTION_UnregisterExtensionInfo( MSIPACKAGE *package )
res = RegDeleteTreeW( HKEY_CLASSES_ROOT, progid_shell );
msi_free( progid_shell );
if (res != ERROR_SUCCESS)
WARN("Failed to delete shell key %d\n", res);
WARN("failed to delete shell key %ld\n", res);
RegDeleteKeyW( HKEY_CLASSES_ROOT, progid );
}
}
......@@ -1482,7 +1482,7 @@ UINT ACTION_UnregisterMIMEInfo( MSIPACKAGE *package )
lstrcatW( mime_key, mime->ContentType );
res = RegDeleteKeyW( HKEY_CLASSES_ROOT, mime_key );
if (res != ERROR_SUCCESS)
WARN("Failed to delete MIME key %d\n", res);
WARN("failed to delete MIME key %ld\n", res);
msi_free( mime_key );
}
......
......@@ -314,7 +314,7 @@ static UINT custom_get_process_return( HANDLE process )
DWORD rc = 0;
GetExitCodeProcess( process, &rc );
TRACE("exit code is %u\n", rc);
TRACE( "exit code is %lu\n", rc );
if (rc != 0)
return ERROR_FUNCTION_FAILED;
return ERROR_SUCCESS;
......@@ -339,7 +339,7 @@ static UINT custom_get_thread_return( MSIPACKAGE *package, HANDLE thread )
ACTION_ForceReboot( package );
return ERROR_SUCCESS;
default:
ERR("Invalid Return Code %d\n",rc);
ERR( "invalid Return Code %lu\n", rc );
return ERROR_INSTALL_FAILURE;
}
}
......@@ -506,13 +506,13 @@ UINT CDECL __wine_msi_call_dll_function(DWORD client_pid, const GUID *guid)
status = RpcStringBindingComposeW(NULL, (WCHAR *)L"ncalrpc", NULL, endpoint, NULL, &binding_str);
if (status != RPC_S_OK)
{
ERR("RpcStringBindingCompose failed: %#x\n", status);
ERR("RpcStringBindingCompose failed: %#lx\n", status);
return status;
}
status = RpcBindingFromStringBindingW(binding_str, &rpc_handle);
if (status != RPC_S_OK)
{
ERR("RpcBindingFromStringBinding failed: %#x\n", status);
ERR("RpcBindingFromStringBinding failed: %#lx\n", status);
return status;
}
RpcStringFreeW(&binding_str);
......@@ -525,7 +525,7 @@ UINT CDECL __wine_msi_call_dll_function(DWORD client_pid, const GUID *guid)
hPackage = alloc_msi_remote_handle( remote_package );
if (!hPackage)
{
ERR( "failed to create handle for %x\n", remote_package );
ERR( "failed to create handle for %#lx\n", remote_package );
midl_user_free( action );
midl_user_free( dll );
midl_user_free( proc );
......@@ -535,7 +535,7 @@ UINT CDECL __wine_msi_call_dll_function(DWORD client_pid, const GUID *guid)
hModule = LoadLibraryW( dll );
if (!hModule)
{
ERR( "failed to load dll %s (%u)\n", debugstr_w( dll ), GetLastError() );
ERR( "failed to load dll %s (%lu)\n", debugstr_w( dll ), GetLastError() );
midl_user_free( action );
midl_user_free( dll );
midl_user_free( proc );
......@@ -555,7 +555,7 @@ UINT CDECL __wine_msi_call_dll_function(DWORD client_pid, const GUID *guid)
}
__EXCEPT_PAGE_FAULT
{
ERR( "Custom action (%s:%s) caused a page fault: %08x\n",
ERR( "Custom action (%s:%s) caused a page fault: %#lx\n",
debugstr_w(dll), debugstr_a(proc), GetExceptionCode() );
r = ERROR_SUCCESS;
}
......@@ -590,7 +590,7 @@ static DWORD custom_start_server(MSIPACKAGE *package, DWORD arch)
pipe = CreateNamedPipeW(buffer, PIPE_ACCESS_DUPLEX, 0, 1, sizeof(DWORD64),
sizeof(GUID), 0, NULL);
if (pipe == INVALID_HANDLE_VALUE)
ERR("Failed to create custom action client pipe: %u\n", GetLastError());
ERR("failed to create custom action client pipe: %lu\n", GetLastError());
if ((sizeof(void *) == 8 || is_wow64) && arch == SCS_32BIT_BINARY)
GetSystemWow64DirectoryW(path, MAX_PATH - ARRAY_SIZE(L"\\msiexec.exe"));
......@@ -623,7 +623,7 @@ static DWORD custom_start_server(MSIPACKAGE *package, DWORD arch)
if (!ConnectNamedPipe(pipe, NULL))
{
ERR("Failed to connect to custom action server: %u\n", GetLastError());
ERR("failed to connect to custom action server: %lu\n", GetLastError());
return GetLastError();
}
......@@ -668,13 +668,13 @@ static DWORD WINAPI custom_client_thread(void *arg)
if (!WriteFile(pipe, &info->guid, sizeof(info->guid), &size, NULL) ||
size != sizeof(info->guid))
{
ERR("Failed to write to custom action client pipe: %u\n", GetLastError());
ERR("failed to write to custom action client pipe: %lu\n", GetLastError());
LeaveCriticalSection(&msi_custom_action_cs);
return GetLastError();
}
if (!ReadFile(pipe, &thread64, sizeof(thread64), &size, NULL) || size != sizeof(thread64))
{
ERR("Failed to read from custom action client pipe: %u\n", GetLastError());
ERR("failed to read from custom action client pipe: %lu\n", GetLastError());
LeaveCriticalSection(&msi_custom_action_cs);
return GetLastError();
}
......@@ -772,7 +772,7 @@ static msi_custom_action_info *do_msidbCustomActionTypeDll(
endpoint, NULL);
if (status != RPC_S_OK)
{
ERR("RpcServerUseProtseqEp failed: %#x\n", status);
ERR("RpcServerUseProtseqEp failed: %#lx\n", status);
return NULL;
}
......@@ -780,7 +780,7 @@ static msi_custom_action_info *do_msidbCustomActionTypeDll(
RPC_IF_AUTOLISTEN, RPC_C_LISTEN_MAX_CALLS_DEFAULT, NULL);
if (status != RPC_S_OK)
{
ERR("RpcServerRegisterIfEx failed: %#x\n", status);
ERR("RpcServerRegisterIfEx failed: %#lx\n", status);
return NULL;
}
......@@ -848,7 +848,7 @@ static HANDLE execute_command( const WCHAR *app, WCHAR *arg, const WCHAR *dir )
}
if (!len_exe)
{
ERR("can't find executable %u\n", GetLastError());
ERR("can't find executable %lu\n", GetLastError());
msi_free( exe );
return INVALID_HANDLE_VALUE;
}
......@@ -886,7 +886,7 @@ static HANDLE execute_command( const WCHAR *app, WCHAR *arg, const WCHAR *dir )
msi_free( exe );
if (!ret)
{
ERR("unable to execute command %u\n", GetLastError());
ERR("unable to execute command %lu\n", GetLastError());
return INVALID_HANDLE_VALUE;
}
CloseHandle( info.hThread );
......@@ -1041,27 +1041,27 @@ static UINT write_substorage_to_file( MSIPACKAGE *package, const WCHAR *source,
hr = StgCreateDocfile( filename, STGM_CREATE|STGM_TRANSACTED|STGM_WRITE|STGM_SHARE_EXCLUSIVE, 0, &dst );
if (FAILED( hr ))
{
WARN( "can't open destination storage %s (%08x)\n", debugstr_w(filename), hr );
WARN( "can't open destination storage %s (%#lx)\n", debugstr_w(filename), hr );
goto done;
}
hr = IStorage_OpenStorage( package->db->storage, source, NULL, STGM_SHARE_EXCLUSIVE, NULL, 0, &src );
if (FAILED( hr ))
{
WARN( "can't open source storage %s (%08x)\n", debugstr_w(source), hr );
WARN( "can't open source storage %s (%#lx)\n", debugstr_w(source), hr );
goto done;
}
hr = IStorage_CopyTo( src, 0, NULL, NULL, dst );
if (FAILED( hr ))
{
ERR( "failed to copy storage %s (%08x)\n", debugstr_w(source), hr );
ERR( "failed to copy storage %s (%#lx)\n", debugstr_w(source), hr );
goto done;
}
hr = IStorage_Commit( dst, 0 );
if (FAILED( hr ))
ERR( "failed to commit storage (%08x)\n", hr );
ERR( "failed to commit storage (%#lx)\n", hr );
else
r = ERROR_SUCCESS;
......@@ -1179,11 +1179,11 @@ static DWORD WINAPI ScriptThread( LPVOID arg )
LPGUID guid = arg;
DWORD rc;
TRACE("custom action (%x) started\n", GetCurrentThreadId() );
TRACE("custom action (%#lx) started\n", GetCurrentThreadId() );
rc = ACTION_CallScript( guid );
TRACE("custom action (%x) returned %i\n", GetCurrentThreadId(), rc );
TRACE("custom action (%#lx) returned %lu\n", GetCurrentThreadId(), rc );
MsiCloseAllHandles();
return rc;
......
......@@ -108,7 +108,7 @@ static HRESULT db_initialize( IStorage *stg, const GUID *clsid )
hr = IStorage_SetClass( stg, clsid );
if (FAILED( hr ))
{
WARN("failed to set class id 0x%08x\n", hr);
WARN("failed to set class id %#lx\n", hr);
return hr;
}
......@@ -116,21 +116,21 @@ static HRESULT db_initialize( IStorage *stg, const GUID *clsid )
hr = write_stream_data( stg, L"_Tables", NULL, 0, TRUE );
if (FAILED( hr ))
{
WARN("failed to create _Tables stream 0x%08x\n", hr);
WARN("failed to create _Tables stream %#lx\n", hr);
return hr;
}
hr = msi_init_string_table( stg );
if (FAILED( hr ))
{
WARN("failed to initialize string table 0x%08x\n", hr);
WARN("failed to initialize string table %#lx\n", hr);
return hr;
}
hr = IStorage_Commit( stg, 0 );
if (FAILED( hr ))
{
WARN("failed to commit changes 0x%08x\n", hr);
WARN("failed to commit changes %#lx\n", hr);
return hr;
}
......@@ -217,7 +217,7 @@ UINT MSI_OpenDatabaseW(LPCWSTR szDBPath, LPCWSTR szPersist, MSIDATABASE **pdb)
if( FAILED( r ) || !stg )
{
WARN("open failed r = %08x for %s\n", r, debugstr_w(szDBPath));
WARN("open failed r = %#lx for %s\n", r, debugstr_w(szDBPath));
return ERROR_FUNCTION_FAILED;
}
......@@ -513,7 +513,7 @@ static LPWSTR msi_build_createsql_columns(LPWSTR *columns_data, LPWSTR *types, D
type = L"LONG";
else
{
WARN("invalid int width %u\n", len);
WARN("invalid int width %lu\n", len);
msi_free(columns);
return NULL;
}
......@@ -835,12 +835,12 @@ done:
return r;
}
UINT WINAPI MsiDatabaseImportW(MSIHANDLE handle, LPCWSTR szFolder, LPCWSTR szFilename)
UINT WINAPI MsiDatabaseImportW( MSIHANDLE handle, const WCHAR *szFolder, const WCHAR *szFilename )
{
MSIDATABASE *db;
UINT r;
TRACE("%x %s %s\n",handle,debugstr_w(szFolder), debugstr_w(szFilename));
TRACE( "%lu %s %s\n", handle, debugstr_w(szFolder), debugstr_w(szFilename) );
if (!(db = msihandle2msiinfo(handle, MSIHANDLETYPE_DATABASE)))
return ERROR_INVALID_HANDLE;
......@@ -850,13 +850,12 @@ UINT WINAPI MsiDatabaseImportW(MSIHANDLE handle, LPCWSTR szFolder, LPCWSTR szFil
return r;
}
UINT WINAPI MsiDatabaseImportA( MSIHANDLE handle,
LPCSTR szFolder, LPCSTR szFilename )
UINT WINAPI MsiDatabaseImportA( MSIHANDLE handle, const char *szFolder, const char *szFilename )
{
LPWSTR path = NULL, file = NULL;
WCHAR *path = NULL, *file = NULL;
UINT r = ERROR_OUTOFMEMORY;
TRACE("%x %s %s\n", handle, debugstr_a(szFolder), debugstr_a(szFilename));
TRACE( "%lu %s %s\n", handle, debugstr_a(szFolder), debugstr_a(szFilename) );
if( szFolder )
{
......@@ -1141,14 +1140,12 @@ done:
*
* row4 : data <tab> data <tab> data <tab> ... data <cr> <lf>
*/
UINT WINAPI MsiDatabaseExportW( MSIHANDLE handle, LPCWSTR szTable,
LPCWSTR szFolder, LPCWSTR szFilename )
UINT WINAPI MsiDatabaseExportW( MSIHANDLE handle, const WCHAR *szTable, const WCHAR *szFolder, const WCHAR *szFilename )
{
MSIDATABASE *db;
UINT r;
TRACE("%x %s %s %s\n", handle, debugstr_w(szTable),
debugstr_w(szFolder), debugstr_w(szFilename));
TRACE( "%lu %s %s %s\n", handle, debugstr_w(szTable), debugstr_w(szFolder), debugstr_w(szFilename) );
if (!(db = msihandle2msiinfo(handle, MSIHANDLETYPE_DATABASE)))
return ERROR_INVALID_HANDLE;
......@@ -1158,14 +1155,12 @@ UINT WINAPI MsiDatabaseExportW( MSIHANDLE handle, LPCWSTR szTable,
return r;
}
UINT WINAPI MsiDatabaseExportA( MSIHANDLE handle, LPCSTR szTable,
LPCSTR szFolder, LPCSTR szFilename )
UINT WINAPI MsiDatabaseExportA( MSIHANDLE handle, const char *szTable, const char *szFolder, const char *szFilename )
{
LPWSTR path = NULL, file = NULL, table = NULL;
WCHAR *path = NULL, *file = NULL, *table = NULL;
UINT r = ERROR_OUTOFMEMORY;
TRACE("%x %s %s %s\n", handle, debugstr_a(szTable),
debugstr_a(szFolder), debugstr_a(szFilename));
TRACE( "%lu %s %s %s\n", handle, debugstr_a(szTable), debugstr_a(szFolder), debugstr_a(szFilename) );
if( szTable )
{
......@@ -1198,14 +1193,12 @@ end:
return r;
}
UINT WINAPI MsiDatabaseMergeA(MSIHANDLE hDatabase, MSIHANDLE hDatabaseMerge,
LPCSTR szTableName)
UINT WINAPI MsiDatabaseMergeA( MSIHANDLE hDatabase, MSIHANDLE hDatabaseMerge, const char *szTableName )
{
UINT r;
LPWSTR table;
WCHAR *table;
TRACE("(%d, %d, %s)\n", hDatabase, hDatabaseMerge,
debugstr_a(szTableName));
TRACE("%lu, %lu, %s\n", hDatabase, hDatabaseMerge, debugstr_a(szTableName) );
table = strdupAtoW(szTableName);
r = MsiDatabaseMergeW(hDatabase, hDatabaseMerge, table);
......@@ -1839,7 +1832,7 @@ static UINT update_merge_errors(MSIDATABASE *db, LPCWSTR error,
return r;
}
UINT WINAPI MsiDatabaseMergeW(MSIHANDLE hDatabase, MSIHANDLE hDatabaseMerge, LPCWSTR szTableName)
UINT WINAPI MsiDatabaseMergeW( MSIHANDLE hDatabase, MSIHANDLE hDatabaseMerge, const WCHAR *szTableName )
{
struct list tabledata = LIST_INIT(tabledata);
struct list *item, *cursor;
......@@ -1848,7 +1841,7 @@ UINT WINAPI MsiDatabaseMergeW(MSIHANDLE hDatabase, MSIHANDLE hDatabaseMerge, LPC
BOOL conflicts;
UINT r;
TRACE("(%d, %d, %s)\n", hDatabase, hDatabaseMerge, debugstr_w(szTableName));
TRACE( "%lu, %lu, %s\n", hDatabase, hDatabaseMerge, debugstr_w(szTableName) );
if (szTableName && !*szTableName)
return ERROR_INVALID_TABLE;
......@@ -1906,7 +1899,7 @@ MSIDBSTATE WINAPI MsiGetDatabaseState( MSIHANDLE handle )
MSIDBSTATE ret = MSIDBSTATE_READ;
MSIDATABASE *db;
TRACE("%d\n", handle);
TRACE( "%lu\n", handle );
if (!(db = msihandle2msiinfo( handle, MSIHANDLETYPE_DATABASE )))
return MSIDBSTATE_ERROR;
......
......@@ -590,7 +590,7 @@ static void dialog_handle_event( msi_dialog *dialog, const WCHAR *control,
val1 = MSI_RecordGetInteger( rec, 2 );
val2 = MSI_RecordGetInteger( rec, 3 );
TRACE("progress: func %u val1 %u val2 %u\n", func, val1, val2);
TRACE( "progress: func %lu val1 %lu val2 %lu\n", func, val1, val2 );
units = val1 / 512;
switch (func)
......@@ -633,7 +633,7 @@ static void dialog_handle_event( msi_dialog *dialog, const WCHAR *control,
ctrl->progress_max += units;
break;
default:
FIXME("Unknown progress message %u\n", func);
FIXME( "unknown progress message %lu\n", func );
break;
}
}
......@@ -730,8 +730,7 @@ static msi_control *msi_dialog_add_control( msi_dialog *dialog,
attributes = MSI_RecordGetInteger( rec, 8 );
if (wcscmp( control_type, L"ScrollableText" )) text = MSI_RecordGetString( rec, 10 );
TRACE("%s, %s, %08x, %s, %08x\n", debugstr_w(szCls), debugstr_w(name),
attributes, debugstr_w(text), style);
TRACE( "%s, %s, %#lx, %s, %#lx\n", debugstr_w(szCls), debugstr_w(name), attributes, debugstr_w(text), style );
if( attributes & msidbControlAttributesVisible )
style |= WS_VISIBLE;
......@@ -773,7 +772,7 @@ MSIText_WndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam)
struct msi_text_info *info;
LRESULT r = 0;
TRACE("%p %04x %08lx %08lx\n", hWnd, msg, wParam, lParam);
TRACE( "%p %04x %#Ix %#Ix\n", hWnd, msg, wParam, lParam );
info = GetPropW(hWnd, L"MSIDATA");
......@@ -1247,7 +1246,7 @@ MSIScrollText_WndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam)
struct msi_scrolltext_info *info;
HRESULT r;
TRACE("%p %04x %08lx %08lx\n", hWnd, msg, wParam, lParam);
TRACE( "%p %04x %#Ix %#Ix\n", hWnd, msg, wParam, lParam );
info = GetPropW( hWnd, L"MSIDATA" );
......@@ -1287,7 +1286,7 @@ msi_richedit_stream_in( DWORD_PTR arg, LPBYTE buffer, LONG count, LONG *pcb )
*pcb = count;
info->offset += count;
TRACE("%d/%d\n", info->offset, info->length);
TRACE( "%lu/%lu\n", info->offset, info->length );
return 0;
}
......@@ -1428,7 +1427,7 @@ static LRESULT WINAPI MSIComboBox_WndProc(HWND hWnd, UINT msg, WPARAM wParam, LP
LRESULT r;
DWORD j;
TRACE("%p %04x %08lx %08lx\n", hWnd, msg, wParam, lParam);
TRACE( "%p %04x %#Ix %#Ix\n", hWnd, msg, wParam, lParam );
info = GetPropW( hWnd, L"MSIDATA" );
if (!info)
......@@ -1828,7 +1827,7 @@ MSIMaskedEdit_WndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam)
struct msi_maskedit_info *info;
HRESULT r;
TRACE("%p %04x %08lx %08lx\n", hWnd, msg, wParam, lParam);
TRACE("%p %04x %#Ix %#Ix\n", hWnd, msg, wParam, lParam);
info = GetPropW(hWnd, L"MSIDATA");
......@@ -2163,7 +2162,7 @@ static LRESULT WINAPI MSIPathEdit_WndProc(HWND hWnd, UINT msg, WPARAM wParam, LP
struct msi_pathedit_info *info = GetPropW(hWnd, L"MSIDATA");
LRESULT r = 0;
TRACE("%p %04x %08lx %08lx\n", hWnd, msg, wParam, lParam);
TRACE("%p %04x %#Ix %#Ix\n", hWnd, msg, wParam, lParam);
if ( msg == WM_KILLFOCUS )
{
......@@ -2262,7 +2261,7 @@ static LRESULT WINAPI MSIRadioGroup_WndProc( HWND hWnd, UINT msg, WPARAM wParam,
WNDPROC oldproc = (WNDPROC)GetPropW( hWnd, L"MSIDATA" );
LRESULT r;
TRACE("hWnd %p msg %04x wParam 0x%08lx lParam 0x%08lx\n", hWnd, msg, wParam, lParam);
TRACE( "hWnd %p msg %04x wParam %#Ix lParam %#Ix\n", hWnd, msg, wParam, lParam );
if (msg == WM_COMMAND) /* Forward notifications to dialog */
SendMessageW( GetParent( hWnd ), msg, wParam, lParam );
......@@ -2463,7 +2462,7 @@ MSISelectionTree_WndProc(HWND hWnd, UINT msg, WPARAM wParam, LPARAM lParam)
TVHITTESTINFO tvhti;
HRESULT r;
TRACE("%p %04x %08lx %08lx\n", hWnd, msg, wParam, lParam);
TRACE("%p %04x %#Ix %#Ix\n", hWnd, msg, wParam, lParam);
info = GetPropW(hWnd, L"MSIDATA");
......@@ -2714,7 +2713,7 @@ static LRESULT WINAPI MSIListBox_WndProc(HWND hWnd, UINT msg, WPARAM wParam, LPA
LRESULT r;
DWORD j;
TRACE("%p %04x %08lx %08lx\n", hWnd, msg, wParam, lParam);
TRACE("%p %04x %#Ix %#Ix\n", hWnd, msg, wParam, lParam);
info = GetPropW( hWnd, L"MSIDATA" );
if (!info)
......@@ -3792,7 +3791,7 @@ static LRESULT msi_dialog_oncommand( msi_dialog *dialog, WPARAM param, HWND hwnd
{
msi_control *control = NULL;
TRACE("%p %p %08lx\n", dialog, hwnd, param);
TRACE( "%p, %#Ix, %p\n", dialog, param, hwnd );
switch (param)
{
......@@ -4214,7 +4213,7 @@ UINT WINAPI MsiEnableUIPreview( MSIHANDLE hdb, MSIHANDLE *phPreview )
MSIPREVIEW *preview;
UINT r = ERROR_FUNCTION_FAILED;
TRACE("%d %p\n", hdb, phPreview);
TRACE( "%lu %p\n", hdb, phPreview );
if (!(db = msihandle2msiinfo(hdb, MSIHANDLETYPE_DATABASE)))
return ERROR_INVALID_HANDLE;
......@@ -4264,7 +4263,7 @@ UINT WINAPI MsiPreviewDialogW( MSIHANDLE hPreview, LPCWSTR szDialogName )
MSIPREVIEW *preview;
UINT r;
TRACE("%d %s\n", hPreview, debugstr_w(szDialogName));
TRACE( "%lu %s\n", hPreview, debugstr_w(szDialogName) );
preview = msihandle2msiinfo( hPreview, MSIHANDLETYPE_PREVIEW );
if (!preview)
......@@ -4280,7 +4279,7 @@ UINT WINAPI MsiPreviewDialogA( MSIHANDLE hPreview, LPCSTR szDialogName )
UINT r;
LPWSTR strW = NULL;
TRACE("%d %s\n", hPreview, debugstr_a(szDialogName));
TRACE( "%lu %s\n", hPreview, debugstr_a(szDialogName) );
if (szDialogName)
{
......@@ -4293,15 +4292,15 @@ UINT WINAPI MsiPreviewDialogA( MSIHANDLE hPreview, LPCSTR szDialogName )
return r;
}
UINT WINAPI MsiPreviewBillboardW( MSIHANDLE hPreview, LPCWSTR szControlName, LPCWSTR szBillboard )
UINT WINAPI MsiPreviewBillboardW( MSIHANDLE hPreview, const WCHAR *szControlName, const WCHAR *szBillboard )
{
FIXME("%d %s %s\n", hPreview, debugstr_w(szControlName), debugstr_w(szBillboard));
FIXME( "%lu %s %s\n", hPreview, debugstr_w(szControlName), debugstr_w(szBillboard) );
return ERROR_CALL_NOT_IMPLEMENTED;
}
UINT WINAPI MsiPreviewBillboardA( MSIHANDLE hPreview, LPCSTR szControlName, LPCSTR szBillboard )
UINT WINAPI MsiPreviewBillboardA( MSIHANDLE hPreview, const char *szControlName, const char *szBillboard )
{
FIXME("%d %s %s\n", hPreview, debugstr_a(szControlName), debugstr_a(szBillboard));
FIXME( "%lu %s %s\n", hPreview, debugstr_a(szControlName), debugstr_a(szBillboard) );
return ERROR_CALL_NOT_IMPLEMENTED;
}
......
......@@ -355,7 +355,7 @@ static msi_file_state calculate_install_state( MSIPACKAGE *package, MSIFILE *fil
}
if ((size = msi_get_disk_file_size( package, file->TargetPath )) != file->FileSize)
{
TRACE("overwriting %s (old size %u new size %u)\n", debugstr_w(file->File), size, file->FileSize);
TRACE("overwriting %s (old size %lu new size %d)\n", debugstr_w(file->File), size, file->FileSize);
return msifs_overwrite;
}
if (file->hash.dwFileHashInfoSize)
......@@ -722,7 +722,7 @@ static UINT patch_file( MSIPACKAGE *package, MSIFILEPATCH *patch )
}
else
{
WARN("failed to patch %s: %08x\n", debugstr_w(patch->File->TargetPath), GetLastError());
WARN( "failed to patch %s: %#lx\n", debugstr_w(patch->File->TargetPath), GetLastError() );
r = ERROR_INSTALL_FAILURE;
}
DeleteFileW( patch->path );
......@@ -761,8 +761,8 @@ static UINT patch_assembly( MSIPACKAGE *package, MSIASSEMBLY *assembly, MSIFILEP
{
if (!msi_copy_file( package, path, patch->File->TargetPath, FALSE ))
{
ERR("Failed to copy file %s -> %s (%u)\n", debugstr_w(path),
debugstr_w(patch->File->TargetPath), GetLastError() );
ERR( "failed to copy file %s -> %s (%lu)\n", debugstr_w(path),
debugstr_w(patch->File->TargetPath), GetLastError() );
msi_free( path );
msi_free( displayname );
IAssemblyName_Release( name );
......@@ -898,7 +898,7 @@ static BOOL move_file( MSIPACKAGE *package, const WCHAR *source, const WCHAR *de
ret = msi_move_file( package, source, dest, MOVEFILE_REPLACE_EXISTING );
if (!ret)
{
WARN("msi_move_file failed: %u\n", GetLastError());
WARN( "msi_move_file failed: %lu\n", GetLastError() );
return FALSE;
}
}
......@@ -908,7 +908,7 @@ static BOOL move_file( MSIPACKAGE *package, const WCHAR *source, const WCHAR *de
ret = msi_copy_file( package, source, dest, FALSE );
if (!ret)
{
WARN("msi_copy_file failed: %u\n", GetLastError());
WARN( "msi_copy_file failed: %lu\n", GetLastError() );
return FALSE;
}
}
......@@ -1176,7 +1176,7 @@ static UINT ITERATE_MoveFiles( MSIRECORD *rec, LPVOID param )
{
if (!msi_create_full_path( package, destdir ))
{
WARN("failed to create directory %u\n", GetLastError());
WARN( "failed to create directory %lu\n", GetLastError() );
goto done;
}
}
......@@ -1317,8 +1317,8 @@ static UINT ITERATE_DuplicateFiles(MSIRECORD *row, LPVOID param)
TRACE("Duplicating file %s to %s\n", debugstr_w(file->TargetPath), debugstr_w(dest));
if (!msi_copy_file( package, file->TargetPath, dest, TRUE ))
{
WARN("Failed to copy file %s -> %s (%u)\n",
debugstr_w(file->TargetPath), debugstr_w(dest), GetLastError());
WARN( "failed to copy file %s -> %s (%lu)\n",
debugstr_w(file->TargetPath), debugstr_w(dest), GetLastError() );
}
FIXME("We should track these duplicate files as well\n");
......@@ -1395,7 +1395,7 @@ static UINT ITERATE_RemoveDuplicateFiles( MSIRECORD *row, LPVOID param )
TRACE("Removing duplicate %s of %s\n", debugstr_w(dest), debugstr_w(file->TargetPath));
if (!msi_delete_file( package, dest ))
{
WARN("Failed to delete duplicate file %s (%u)\n", debugstr_w(dest), GetLastError());
WARN( "failed to delete duplicate file %s (%lu)\n", debugstr_w(dest), GetLastError() );
}
uirow = MSI_CreateRecord( 9 );
......@@ -1606,7 +1606,7 @@ UINT ACTION_RemoveFiles( MSIPACKAGE *package )
msi_set_file_attributes( package, file->TargetPath, FILE_ATTRIBUTE_NORMAL );
if (!msi_delete_file( package, file->TargetPath ))
{
WARN("failed to delete %s (%u)\n", debugstr_w(file->TargetPath), GetLastError());
WARN( "failed to delete %s (%lu)\n", debugstr_w(file->TargetPath), GetLastError() );
}
file->state = msifs_missing;
......
......@@ -897,14 +897,13 @@ end:
return rc;
}
UINT WINAPI MsiFormatRecordW( MSIHANDLE hInstall, MSIHANDLE hRecord,
LPWSTR szResult, LPDWORD sz )
UINT WINAPI MsiFormatRecordW( MSIHANDLE hInstall, MSIHANDLE hRecord, WCHAR *szResult, DWORD *sz )
{
UINT r = ERROR_INVALID_HANDLE;
MSIPACKAGE *package;
MSIRECORD *record;
TRACE("%d %d %p %p\n", hInstall, hRecord, szResult, sz);
TRACE( "%lu, %lu, %p, %p\n", hInstall, hRecord, szResult, sz );
record = msihandle2msiinfo(hRecord, MSIHANDLETYPE_RECORD);
if (!record)
......@@ -961,7 +960,7 @@ UINT WINAPI MsiFormatRecordA(MSIHANDLE hinst, MSIHANDLE hrec, char *buf, DWORD *
DWORD len;
UINT r;
TRACE("%d %d %p %p\n", hinst, hrec, buf, sz);
TRACE( "%lu, %lu, %p, %p\n", hinst, hrec, buf, sz );
rec = msihandle2msiinfo(hrec, MSIHANDLETYPE_RECORD);
if (!rec)
......
......@@ -127,7 +127,7 @@ MSIHANDLE alloc_msihandle( MSIOBJECTHDR *obj )
LeaveCriticalSection( &MSI_handle_cs );
TRACE("%p -> %d\n", obj, ret );
TRACE( "%p -> %lu\n", obj, ret );
return ret;
}
......@@ -150,7 +150,7 @@ MSIHANDLE alloc_msi_remote_handle(MSIHANDLE remote)
LeaveCriticalSection( &MSI_handle_cs );
TRACE("%d -> %d\n", remote, ret);
TRACE( "%lu -> %lu\n", remote, ret );
return ret;
}
......@@ -271,7 +271,7 @@ UINT WINAPI MsiCloseHandle(MSIHANDLE handle)
MSIOBJECTHDR *info = NULL;
UINT ret = ERROR_INVALID_HANDLE;
TRACE("%x\n",handle);
TRACE( "%lu\n", handle );
if (!handle)
return ERROR_SUCCESS;
......@@ -305,7 +305,7 @@ UINT WINAPI MsiCloseHandle(MSIHANDLE handle)
ret = ERROR_SUCCESS;
TRACE("handle %x destroyed\n", handle+1);
TRACE( "handle %lu destroyed\n", handle + 1 );
out:
LeaveCriticalSection( &MSI_handle_cs );
if( info )
......
......@@ -79,7 +79,7 @@ MSIRECORD *msi_query_merge_record( UINT fields, const column_info *vl, MSIRECORD
switch( vl->val->type )
{
case EXPR_SVAL:
TRACE("field %d -> %s\n", i, debugstr_w(vl->val->u.sval));
TRACE( "field %lu -> %s\n", i, debugstr_w(vl->val->u.sval) );
MSI_RecordSetStringW( merged, i, vl->val->u.sval );
break;
case EXPR_IVAL:
......
......@@ -672,7 +672,7 @@ BOOL WINAPI MsiGetMode(MSIHANDLE hInstall, MSIRUNMODE iRunMode)
MSIPACKAGE *package;
BOOL r = FALSE;
TRACE("%d %d\n", hInstall, iRunMode);
TRACE( "%lu, %d\n", hInstall, iRunMode );
package = msihandle2msiinfo(hInstall, MSIHANDLETYPE_PACKAGE);
if (!package)
......@@ -765,7 +765,7 @@ UINT WINAPI MsiSetMode(MSIHANDLE hInstall, MSIRUNMODE iRunMode, BOOL fState)
MSIPACKAGE *package;
UINT r;
TRACE("%d %d %d\n", hInstall, iRunMode, fState);
TRACE( "%lu, %d, %d\n", hInstall, iRunMode, fState );
package = msihandle2msiinfo( hInstall, MSIHANDLETYPE_PACKAGE );
if (!package)
......@@ -990,7 +990,7 @@ UINT WINAPI MsiSetFeatureAttributesA( MSIHANDLE handle, LPCSTR feature, DWORD at
UINT r;
WCHAR *featureW = NULL;
TRACE("%u, %s, 0x%08x\n", handle, debugstr_a(feature), attrs);
TRACE( "%lu, %s, %#lx\n", handle, debugstr_a(feature), attrs );
if (feature && !(featureW = strdupAtoW( feature ))) return ERROR_OUTOFMEMORY;
......@@ -1021,7 +1021,7 @@ UINT WINAPI MsiSetFeatureAttributesW( MSIHANDLE handle, LPCWSTR name, DWORD attr
MSIFEATURE *feature;
WCHAR *costing;
TRACE("%u, %s, 0x%08x\n", handle, debugstr_w(name), attrs);
TRACE( "%lu, %s, %#lx\n", handle, debugstr_w(name), attrs );
if (!name || !name[0]) return ERROR_UNKNOWN_FEATURE;
......@@ -1085,13 +1085,13 @@ UINT MSI_GetFeatureStateW(MSIPACKAGE *package, LPCWSTR szFeature,
/***********************************************************************
* MsiGetFeatureStateW (MSI.@)
*/
UINT WINAPI MsiGetFeatureStateW(MSIHANDLE hInstall, LPCWSTR szFeature,
INSTALLSTATE *piInstalled, INSTALLSTATE *piAction)
UINT WINAPI MsiGetFeatureStateW( MSIHANDLE hInstall, const WCHAR *szFeature, INSTALLSTATE *piInstalled,
INSTALLSTATE *piAction )
{
MSIPACKAGE* package;
UINT ret;
TRACE("%d %s %p %p\n", hInstall, debugstr_w(szFeature), piInstalled, piAction);
TRACE( "%lu, %s, %p, %p\n", hInstall, debugstr_w(szFeature), piInstalled, piAction );
if (!szFeature)
return ERROR_UNKNOWN_FEATURE;
......@@ -1204,15 +1204,14 @@ UINT MSI_GetFeatureCost( MSIPACKAGE *package, MSIFEATURE *feature, MSICOSTTREE t
/***********************************************************************
* MsiGetFeatureCostW (MSI.@)
*/
UINT WINAPI MsiGetFeatureCostW(MSIHANDLE hInstall, LPCWSTR szFeature,
MSICOSTTREE iCostTree, INSTALLSTATE iState, LPINT piCost)
UINT WINAPI MsiGetFeatureCostW( MSIHANDLE hInstall, const WCHAR *szFeature, MSICOSTTREE iCostTree,
INSTALLSTATE iState, INT *piCost )
{
MSIPACKAGE *package;
MSIFEATURE *feature;
UINT ret;
TRACE("(%d %s %i %i %p)\n", hInstall, debugstr_w(szFeature),
iCostTree, iState, piCost);
TRACE( "%lu, %s, %d, %d, %p\n", hInstall, debugstr_w(szFeature), iCostTree, iState, piCost );
if (!szFeature)
return ERROR_INVALID_PARAMETER;
......@@ -1258,14 +1257,14 @@ UINT WINAPI MsiGetFeatureCostW(MSIHANDLE hInstall, LPCWSTR szFeature,
/***********************************************************************
* MsiGetFeatureInfoA (MSI.@)
*/
UINT WINAPI MsiGetFeatureInfoA( MSIHANDLE handle, LPCSTR feature, LPDWORD attrs,
LPSTR title, LPDWORD title_len, LPSTR help, LPDWORD help_len )
UINT WINAPI MsiGetFeatureInfoA( MSIHANDLE handle, const char *feature, DWORD *attrs,
char *title, DWORD *title_len, char *help, DWORD *help_len )
{
UINT r;
WCHAR *titleW = NULL, *helpW = NULL, *featureW = NULL;
TRACE("%u, %s, %p, %p, %p, %p, %p\n", handle, debugstr_a(feature), attrs, title,
title_len, help, help_len);
TRACE( "%lu, %s, %p, %p, %p, %p, %p\n", handle, debugstr_a(feature), attrs, title,
title_len, help, help_len );
if (feature && !(featureW = strdupAtoW( feature ))) return ERROR_OUTOFMEMORY;
......@@ -1352,14 +1351,14 @@ static UINT MSI_GetFeatureInfo( MSIPACKAGE *package, LPCWSTR name, LPDWORD attrs
/***********************************************************************
* MsiGetFeatureInfoW (MSI.@)
*/
UINT WINAPI MsiGetFeatureInfoW( MSIHANDLE handle, LPCWSTR feature, LPDWORD attrs,
LPWSTR title, LPDWORD title_len, LPWSTR help, LPDWORD help_len )
UINT WINAPI MsiGetFeatureInfoW( MSIHANDLE handle, const WCHAR *feature, DWORD *attrs,
WCHAR *title, DWORD *title_len, WCHAR *help, DWORD *help_len )
{
UINT r;
MSIPACKAGE *package;
TRACE("%u, %s, %p, %p, %p, %p, %p\n", handle, debugstr_w(feature), attrs, title,
title_len, help, help_len);
TRACE( "%lu, %s, %p, %p, %p, %p, %p\n", handle, debugstr_w(feature), attrs, title,
title_len, help, help_len );
if (!feature) return ERROR_INVALID_PARAMETER;
......@@ -1499,14 +1498,13 @@ UINT WINAPI MsiSetComponentStateW(MSIHANDLE hInstall, LPCWSTR szComponent,
/***********************************************************************
* MsiGetComponentStateW (MSI.@)
*/
UINT WINAPI MsiGetComponentStateW(MSIHANDLE hInstall, LPCWSTR szComponent,
INSTALLSTATE *piInstalled, INSTALLSTATE *piAction)
UINT WINAPI MsiGetComponentStateW( MSIHANDLE hInstall, const WCHAR *szComponent, INSTALLSTATE *piInstalled,
INSTALLSTATE *piAction )
{
MSIPACKAGE* package;
UINT ret;
TRACE("%d %s %p %p\n", hInstall, debugstr_w(szComponent),
piInstalled, piAction);
TRACE( "%lu, %s, %p, %p\n", hInstall, debugstr_w(szComponent), piInstalled, piAction );
if (!szComponent)
return ERROR_UNKNOWN_COMPONENT;
......@@ -1601,7 +1599,7 @@ UINT WINAPI MsiSetInstallLevel(MSIHANDLE hInstall, int iInstallLevel)
MSIPACKAGE* package;
UINT r;
TRACE("%d %i\n", hInstall, iInstallLevel);
TRACE( "%lu %d\n", hInstall, iInstallLevel );
package = msihandle2msiinfo(hInstall, MSIHANDLETYPE_PACKAGE);
if (!package)
......@@ -1634,28 +1632,22 @@ UINT WINAPI MsiSetInstallLevel(MSIHANDLE hInstall, int iInstallLevel)
/***********************************************************************
* MsiGetFeatureValidStatesW (MSI.@)
*/
UINT WINAPI MsiGetFeatureValidStatesW(MSIHANDLE hInstall, LPCWSTR szFeature,
LPDWORD pInstallState)
UINT WINAPI MsiGetFeatureValidStatesW( MSIHANDLE hInstall, const WCHAR *szFeature, DWORD *pInstallState )
{
if(pInstallState) *pInstallState = 1<<INSTALLSTATE_LOCAL;
FIXME("%d %s %p stub returning %d\n",
hInstall, debugstr_w(szFeature), pInstallState, pInstallState ? *pInstallState : 0);
if (pInstallState) *pInstallState = 1 << INSTALLSTATE_LOCAL;
FIXME( "%lu, %s, %p stub returning %lu\n", hInstall, debugstr_w(szFeature), pInstallState,
pInstallState ? *pInstallState : 0 );
return ERROR_SUCCESS;
}
/***********************************************************************
* MsiGetFeatureValidStatesA (MSI.@)
*/
UINT WINAPI MsiGetFeatureValidStatesA(MSIHANDLE hInstall, LPCSTR szFeature,
LPDWORD pInstallState)
UINT WINAPI MsiGetFeatureValidStatesA( MSIHANDLE hInstall, const char *szFeature, DWORD *pInstallState )
{
UINT ret;
LPWSTR szwFeature = strdupAtoW(szFeature);
WCHAR *szwFeature = strdupAtoW(szFeature);
ret = MsiGetFeatureValidStatesW(hInstall, szwFeature, pInstallState);
msi_free(szwFeature);
return ret;
}
......@@ -64,7 +64,7 @@ static BOOL source_matches_volume(MSIMEDIAINFO *mi, LPCWSTR source_root)
if (!GetVolumeInformationW(root, volume_name, MAX_PATH + 1, NULL, NULL, NULL, NULL, 0))
{
WARN("failed to get volume information for %s (%u)\n", debugstr_w(root), GetLastError());
WARN( "failed to get volume information for %s (%lu)\n", debugstr_w(root), GetLastError() );
return FALSE;
}
......@@ -227,7 +227,7 @@ static INT_PTR CDECL cabinet_open_stream( char *pszFile, int oflag, int pmode )
msi_free( encoded );
if (FAILED(hr))
{
WARN("failed to open stream 0x%08x\n", hr);
WARN( "failed to open stream %#lx\n", hr );
return -1;
}
}
......@@ -349,7 +349,7 @@ static INT_PTR cabinet_next_cabinet(FDINOTIFICATIONTYPE fdint,
length = strlen(pfdin->psz3) + 1 + strlen(next_cab) + 1;
if (length > 256)
{
WARN("Cannot update next cabinet filename with a string size %u > 256\n", length);
WARN( "cannot update next cabinet filename with a string size %lu > 256\n", length );
msi_free(next_cab);
goto done;
}
......@@ -441,7 +441,7 @@ static INT_PTR cabinet_copy_file(FDINOTIFICATIONTYPE fdint,
if (attrs2 == INVALID_FILE_ATTRIBUTES)
{
ERR("failed to create %s (error %d)\n", debugstr_w(path), err);
ERR( "failed to create %s (error %lu)\n", debugstr_w(path), err );
goto done;
}
else if (err == ERROR_ACCESS_DENIED && (attrs2 & FILE_ATTRIBUTE_READONLY))
......@@ -481,13 +481,12 @@ static INT_PTR cabinet_copy_file(FDINOTIFICATIONTYPE fdint,
}
else
{
WARN("failed to schedule rename operation %s (error %d)\n", debugstr_w(path), GetLastError());
WARN( "failed to schedule rename operation %s (error %lu)\n", debugstr_w(path), GetLastError() );
DeleteFileW( tmpfileW );
}
msi_free(tmpfileW);
}
else
WARN("failed to create %s (error %d)\n", debugstr_w(path), err);
else WARN( "failed to create %s (error %lu)\n", debugstr_w(path), err );
}
done:
......
......@@ -85,13 +85,12 @@ UINT VIEW_find_column( MSIVIEW *table, LPCWSTR name, LPCWSTR table_name, UINT *n
return ERROR_INVALID_PARAMETER;
}
UINT WINAPI MsiDatabaseOpenViewA(MSIHANDLE hdb,
LPCSTR szQuery, MSIHANDLE *phView)
UINT WINAPI MsiDatabaseOpenViewA( MSIHANDLE hdb, const char *szQuery, MSIHANDLE *phView )
{
UINT r;
LPWSTR szwQuery;
WCHAR *szwQuery;
TRACE("%d %s %p\n", hdb, debugstr_a(szQuery), phView);
TRACE( "%lu, %s, %p\n", hdb, debugstr_a(szQuery), phView );
if( szQuery )
{
......@@ -108,13 +107,12 @@ UINT WINAPI MsiDatabaseOpenViewA(MSIHANDLE hdb,
return r;
}
UINT MSI_DatabaseOpenViewW(MSIDATABASE *db,
LPCWSTR szQuery, MSIQUERY **pView)
UINT MSI_DatabaseOpenViewW( MSIDATABASE *db, const WCHAR *szQuery, MSIQUERY **pView )
{
MSIQUERY *query;
UINT r;
TRACE("%s %p\n", debugstr_w(szQuery), pView);
TRACE( "%s, %p\n", debugstr_w(szQuery), pView );
/* pre allocate a handle to hold a pointer to the view */
query = alloc_msiobject( MSIHANDLETYPE_VIEW, sizeof (MSIQUERY),
......@@ -403,13 +401,13 @@ UINT MSI_ViewFetch(MSIQUERY *query, MSIRECORD **prec)
return r;
}
UINT WINAPI MsiViewFetch(MSIHANDLE hView, MSIHANDLE *record)
UINT WINAPI MsiViewFetch( MSIHANDLE hView, MSIHANDLE *record )
{
MSIQUERY *query;
MSIRECORD *rec = NULL;
UINT ret;
TRACE("%d %p\n", hView, record);
TRACE( "%lu, %p\n", hView, record );
if( !record )
return ERROR_INVALID_PARAMETER;
......@@ -468,12 +466,12 @@ UINT MSI_ViewClose(MSIQUERY *query)
return view->ops->close( view );
}
UINT WINAPI MsiViewClose(MSIHANDLE hView)
UINT WINAPI MsiViewClose( MSIHANDLE hView )
{
MSIQUERY *query;
UINT ret;
TRACE("%d\n", hView );
TRACE( "%lu\n", hView );
query = msihandle2msiinfo( hView, MSIHANDLETYPE_VIEW );
if (!query)
......@@ -517,13 +515,13 @@ UINT MSI_ViewExecute(MSIQUERY *query, MSIRECORD *rec )
return view->ops->execute( view, rec );
}
UINT WINAPI MsiViewExecute(MSIHANDLE hView, MSIHANDLE hRec)
UINT WINAPI MsiViewExecute( MSIHANDLE hView, MSIHANDLE hRec )
{
MSIQUERY *query;
MSIRECORD *rec = NULL;
UINT ret;
TRACE("%d %d\n", hView, hRec);
TRACE( "%lu, %lu\n", hView, hRec );
if( hRec )
{
......@@ -641,13 +639,13 @@ UINT MSI_ViewGetColumnInfo( MSIQUERY *query, MSICOLINFO info, MSIRECORD **prec )
return ERROR_SUCCESS;
}
UINT WINAPI MsiViewGetColumnInfo(MSIHANDLE hView, MSICOLINFO info, MSIHANDLE *hRec)
UINT WINAPI MsiViewGetColumnInfo( MSIHANDLE hView, MSICOLINFO info, MSIHANDLE *hRec )
{
MSIQUERY *query = NULL;
MSIRECORD *rec = NULL;
UINT r;
TRACE("%d %d %p\n", hView, info, hRec);
TRACE( "%lu, %d, %p\n", hView, info, hRec );
if( !hRec )
return ERROR_INVALID_PARAMETER;
......@@ -719,14 +717,13 @@ UINT MSI_ViewModify( MSIQUERY *query, MSIMODIFY mode, MSIRECORD *rec )
return r;
}
UINT WINAPI MsiViewModify( MSIHANDLE hView, MSIMODIFY eModifyMode,
MSIHANDLE hRecord)
UINT WINAPI MsiViewModify( MSIHANDLE hView, MSIMODIFY eModifyMode, MSIHANDLE hRecord )
{
MSIQUERY *query = NULL;
MSIRECORD *rec = NULL;
UINT r = ERROR_FUNCTION_FAILED;
TRACE("%d %x %d\n", hView, eModifyMode, hRecord);
TRACE( "%lu, %#x, %lu\n", hView, eModifyMode, hRecord );
rec = msihandle2msiinfo( hRecord, MSIHANDLETYPE_RECORD );
......@@ -770,13 +767,13 @@ UINT WINAPI MsiViewModify( MSIHANDLE hView, MSIMODIFY eModifyMode,
return r;
}
MSIDBERROR WINAPI MsiViewGetErrorW( MSIHANDLE handle, LPWSTR buffer, LPDWORD buflen )
MSIDBERROR WINAPI MsiViewGetErrorW( MSIHANDLE handle, WCHAR *buffer, DWORD *buflen )
{
MSIQUERY *query;
const WCHAR *column;
MSIDBERROR r;
TRACE("%u %p %p\n", handle, buffer, buflen);
TRACE( "%lu, %p, %p\n", handle, buffer, buflen );
if (!buflen)
return MSIDBERROR_INVALIDARG;
......@@ -821,13 +818,13 @@ MSIDBERROR WINAPI MsiViewGetErrorW( MSIHANDLE handle, LPWSTR buffer, LPDWORD buf
return r;
}
MSIDBERROR WINAPI MsiViewGetErrorA( MSIHANDLE handle, LPSTR buffer, LPDWORD buflen )
MSIDBERROR WINAPI MsiViewGetErrorA( MSIHANDLE handle, char *buffer, DWORD *buflen )
{
MSIQUERY *query;
const WCHAR *column;
MSIDBERROR r;
TRACE("%u %p %p\n", handle, buffer, buflen);
TRACE( "%lu, %p, %p\n", handle, buffer, buflen );
if (!buflen)
return MSIDBERROR_INVALIDARG;
......@@ -892,7 +889,7 @@ UINT MSI_DatabaseApplyTransformW( MSIDATABASE *db, const WCHAR *transform, int e
hr = IStorage_OpenStorage( db->storage, transform + 1, NULL, STGM_SHARE_EXCLUSIVE, NULL, 0, &stg );
if (FAILED( hr ))
{
WARN( "failed to open substorage transform 0x%08x\n", hr );
WARN( "failed to open substorage transform %#lx\n", hr );
return ERROR_FUNCTION_FAILED;
}
}
......@@ -901,7 +898,7 @@ UINT MSI_DatabaseApplyTransformW( MSIDATABASE *db, const WCHAR *transform, int e
hr = StgOpenStorage( transform, NULL, STGM_DIRECT|STGM_READ|STGM_SHARE_DENY_WRITE, NULL, 0, &stg );
if (FAILED( hr ))
{
WARN( "failed to open file transform 0x%08x\n", hr );
WARN( "failed to open file transform %#lx\n", hr );
return ERROR_FUNCTION_FAILED;
}
}
......@@ -938,7 +935,7 @@ UINT WINAPI MsiDatabaseApplyTransformA( MSIHANDLE hdb, const char *transform, in
WCHAR *wstr;
UINT ret;
TRACE( "%d %s %08x\n", hdb, debugstr_a(transform), error_cond );
TRACE( "%lu, %s, %#x\n", hdb, debugstr_a(transform), error_cond );
wstr = strdupAtoW( transform );
if (transform && !wstr)
......@@ -949,19 +946,17 @@ UINT WINAPI MsiDatabaseApplyTransformA( MSIHANDLE hdb, const char *transform, in
return ret;
}
UINT WINAPI MsiDatabaseGenerateTransformA( MSIHANDLE hdb, MSIHANDLE hdbref,
LPCSTR szTransformFile, int iReserved1, int iReserved2 )
UINT WINAPI MsiDatabaseGenerateTransformA( MSIHANDLE hdb, MSIHANDLE hdbref, const char *szTransformFile,
int iReserved1, int iReserved2 )
{
FIXME("%d %d %s %d %d\n", hdb, hdbref,
debugstr_a(szTransformFile), iReserved1, iReserved2);
FIXME( "%lu, %lu, %s, %d, %d\n", hdb, hdbref, debugstr_a(szTransformFile), iReserved1, iReserved2 );
return ERROR_CALL_NOT_IMPLEMENTED;
}
UINT WINAPI MsiDatabaseGenerateTransformW( MSIHANDLE hdb, MSIHANDLE hdbref,
LPCWSTR szTransformFile, int iReserved1, int iReserved2 )
UINT WINAPI MsiDatabaseGenerateTransformW( MSIHANDLE hdb, MSIHANDLE hdbref, const WCHAR *szTransformFile,
int iReserved1, int iReserved2 )
{
FIXME("%d %d %s %d %d\n", hdb, hdbref,
debugstr_w(szTransformFile), iReserved1, iReserved2);
FIXME( "%lu, %lu, %s, %d, %d\n", hdb, hdbref, debugstr_w(szTransformFile), iReserved1, iReserved2 );
return ERROR_CALL_NOT_IMPLEMENTED;
}
......@@ -970,7 +965,7 @@ UINT WINAPI MsiDatabaseCommit( MSIHANDLE hdb )
MSIDATABASE *db;
UINT r;
TRACE("%d\n", hdb);
TRACE( "%lu\n", hdb );
db = msihandle2msiinfo( hdb, MSIHANDLETYPE_DATABASE );
if( !db )
......@@ -1066,7 +1061,7 @@ UINT MSI_DatabaseGetPrimaryKeys( MSIDATABASE *db,
r = MSI_IterateRecords( query, 0, msi_primary_key_iterator, &info );
if( r == ERROR_SUCCESS )
{
TRACE("Found %d primary keys\n", info.n );
TRACE( "found %lu primary keys\n", info.n );
/* allocate a record and fill in the names of the tables */
info.rec = MSI_CreateRecord( info.n );
......@@ -1082,14 +1077,13 @@ UINT MSI_DatabaseGetPrimaryKeys( MSIDATABASE *db,
return r;
}
UINT WINAPI MsiDatabaseGetPrimaryKeysW( MSIHANDLE hdb,
LPCWSTR table, MSIHANDLE* phRec )
UINT WINAPI MsiDatabaseGetPrimaryKeysW( MSIHANDLE hdb, const WCHAR *table, MSIHANDLE *phRec )
{
MSIRECORD *rec = NULL;
MSIDATABASE *db;
UINT r;
TRACE("%d %s %p\n", hdb, debugstr_w(table), phRec);
TRACE( "%lu, %s, %p\n", hdb, debugstr_w(table), phRec );
db = msihandle2msiinfo( hdb, MSIHANDLETYPE_DATABASE );
if( !db )
......@@ -1132,13 +1126,12 @@ UINT WINAPI MsiDatabaseGetPrimaryKeysW( MSIHANDLE hdb,
return r;
}
UINT WINAPI MsiDatabaseGetPrimaryKeysA(MSIHANDLE hdb,
LPCSTR table, MSIHANDLE* phRec)
UINT WINAPI MsiDatabaseGetPrimaryKeysA( MSIHANDLE hdb, const char *table, MSIHANDLE *phRec )
{
LPWSTR szwTable = NULL;
WCHAR *szwTable = NULL;
UINT r;
TRACE("%d %s %p\n", hdb, debugstr_a(table), phRec);
TRACE( "%lu, %s, %p\n", hdb, debugstr_a(table), phRec );
if( table )
{
......@@ -1152,13 +1145,12 @@ UINT WINAPI MsiDatabaseGetPrimaryKeysA(MSIHANDLE hdb,
return r;
}
MSICONDITION WINAPI MsiDatabaseIsTablePersistentA(
MSIHANDLE hDatabase, LPCSTR szTableName)
MSICONDITION WINAPI MsiDatabaseIsTablePersistentA( MSIHANDLE hDatabase, const char *szTableName )
{
LPWSTR szwTableName = NULL;
WCHAR *szwTableName = NULL;
MSICONDITION r;
TRACE("%x %s\n", hDatabase, debugstr_a(szTableName));
TRACE( "%lu, %s\n", hDatabase, debugstr_a(szTableName) );
if( szTableName )
{
......@@ -1172,13 +1164,12 @@ MSICONDITION WINAPI MsiDatabaseIsTablePersistentA(
return r;
}
MSICONDITION WINAPI MsiDatabaseIsTablePersistentW(
MSIHANDLE hDatabase, LPCWSTR szTableName)
MSICONDITION WINAPI MsiDatabaseIsTablePersistentW( MSIHANDLE hDatabase, const WCHAR *szTableName )
{
MSIDATABASE *db;
MSICONDITION r;
TRACE("%x %s\n", hDatabase, debugstr_w(szTableName));
TRACE( "%lu, %s\n", hDatabase, debugstr_w(szTableName) );
db = msihandle2msiinfo( hDatabase, MSIHANDLETYPE_DATABASE );
if( !db )
......
......@@ -291,7 +291,7 @@ static void free_package_structures( MSIPACKAGE *package )
list_remove( &binary->entry );
if (!DeleteFileW( binary->tmpfile ))
ERR("failed to delete %s (%u)\n", debugstr_w(binary->tmpfile), GetLastError());
ERR( "failed to delete %s (%lu)\n", debugstr_w(binary->tmpfile), GetLastError() );
msi_free( binary->source );
msi_free( binary->tmpfile );
msi_free( binary );
......@@ -314,7 +314,7 @@ static void free_package_structures( MSIPACKAGE *package )
list_remove( &patch->entry );
if (patch->delete_on_close && !DeleteFileW( patch->localfile ))
{
ERR("failed to delete %s (%u)\n", debugstr_w(patch->localfile), GetLastError());
ERR( "failed to delete %s (%lu)\n", debugstr_w(patch->localfile), GetLastError() );
}
msi_free_patchinfo( patch );
}
......@@ -1546,12 +1546,12 @@ UINT MSI_OpenPackageW(LPCWSTR szPackage, DWORD dwOptions, MSIPACKAGE **pPackage)
return ERROR_SUCCESS;
}
UINT WINAPI MsiOpenPackageExW(LPCWSTR szPackage, DWORD dwOptions, MSIHANDLE *phPackage)
UINT WINAPI MsiOpenPackageExW( const WCHAR *szPackage, DWORD dwOptions, MSIHANDLE *phPackage )
{
MSIPACKAGE *package = NULL;
UINT ret;
TRACE("%s %08x %p\n", debugstr_w(szPackage), dwOptions, phPackage );
TRACE( "%s, %#lx, %p\n", debugstr_w(szPackage), dwOptions, phPackage );
if( !szPackage || !phPackage )
return ERROR_INVALID_PARAMETER;
......@@ -1563,7 +1563,7 @@ UINT WINAPI MsiOpenPackageExW(LPCWSTR szPackage, DWORD dwOptions, MSIHANDLE *phP
}
if( dwOptions )
FIXME("dwOptions %08x not supported\n", dwOptions);
FIXME( "dwOptions %#lx not supported\n", dwOptions );
ret = MSI_OpenPackageW( szPackage, 0, &package );
if( ret == ERROR_SUCCESS )
......@@ -1608,13 +1608,13 @@ UINT WINAPI MsiOpenPackageA(LPCSTR szPackage, MSIHANDLE *phPackage)
return MsiOpenPackageExA( szPackage, 0, phPackage );
}
MSIHANDLE WINAPI MsiGetActiveDatabase(MSIHANDLE hInstall)
MSIHANDLE WINAPI MsiGetActiveDatabase( MSIHANDLE hInstall )
{
MSIPACKAGE *package;
MSIHANDLE handle = 0;
MSIHANDLE remote;
TRACE("(%d)\n",hInstall);
TRACE( "%lu\n", hInstall );
package = msihandle2msiinfo( hInstall, MSIHANDLETYPE_PACKAGE);
if( package)
......@@ -1814,21 +1814,21 @@ INT MSI_ProcessMessageVerbatim(MSIPACKAGE *package, INSTALLMESSAGE eMessageType,
if (gUIHandlerRecord && (gUIFilterRecord & log_type))
{
MSIHANDLE rec = alloc_msihandle(&record->hdr);
TRACE("Calling UI handler %p(pvContext=%p, iMessageType=%08x, hRecord=%u)\n",
gUIHandlerRecord, gUIContextRecord, eMessageType, rec);
TRACE( "calling UI handler %p(pvContext = %p, iMessageType = %#x, hRecord = %lu)\n",
gUIHandlerRecord, gUIContextRecord, eMessageType, rec );
rc = gUIHandlerRecord( gUIContextRecord, eMessageType, rec );
MsiCloseHandle( rec );
}
if (!rc && gUIHandlerW && (gUIFilter & log_type))
{
TRACE("Calling UI handler %p(pvContext=%p, iMessageType=%08x, szMessage=%s)\n",
gUIHandlerW, gUIContext, eMessageType, debugstr_w(message));
TRACE( "calling UI handler %p(pvContext = %p, iMessageType = %#x, szMessage = %s)\n",
gUIHandlerW, gUIContext, eMessageType, debugstr_w(message) );
rc = gUIHandlerW( gUIContext, eMessageType, message );
}
else if (!rc && gUIHandlerA && (gUIFilter & log_type))
{
TRACE("Calling UI handler %p(pvContext=%p, iMessageType=%08x, szMessage=%s)\n",
gUIHandlerA, gUIContext, eMessageType, debugstr_a(msg));
TRACE( "calling UI handler %p(pvContext = %p, iMessageType = %#x, szMessage = %s)\n",
gUIHandlerA, gUIContext, eMessageType, debugstr_a(msg) );
rc = gUIHandlerA( gUIContext, eMessageType, msg );
}
......@@ -2207,8 +2207,7 @@ UINT msi_get_property( MSIDATABASE *db, LPCWSTR szName,
TRACE("returning %s for property %s\n", debugstr_wn(szValueBuf, *pchValueBuf),
debugstr_w(szName));
else if (rc == ERROR_MORE_DATA)
TRACE("need %d sized buffer for %s\n", *pchValueBuf,
debugstr_w(szName));
TRACE( "need %lu sized buffer for %s\n", *pchValueBuf, debugstr_w(szName) );
else
{
*pchValueBuf = 0;
......
......@@ -115,7 +115,7 @@ UINT WINAPI MsiRecordGetFieldCount( MSIHANDLE handle )
MSIRECORD *rec;
UINT ret;
TRACE("%d\n", handle );
TRACE( "%lu\n", handle );
rec = msihandle2msiinfo( handle, MSIHANDLETYPE_RECORD );
if( !rec )
......@@ -239,7 +239,7 @@ int WINAPI MsiRecordGetInteger( MSIHANDLE handle, UINT iField)
MSIRECORD *rec;
UINT ret;
TRACE("%d %d\n", handle, iField );
TRACE( "%lu, %u\n", handle, iField );
rec = msihandle2msiinfo( handle, MSIHANDLETYPE_RECORD );
if( !rec )
......@@ -258,7 +258,7 @@ UINT WINAPI MsiRecordClearData( MSIHANDLE handle )
MSIRECORD *rec;
UINT i;
TRACE("%d\n", handle );
TRACE( "%lu\n", handle );
rec = msihandle2msiinfo( handle, MSIHANDLETYPE_RECORD );
if( !rec )
......@@ -305,7 +305,7 @@ UINT WINAPI MsiRecordSetInteger( MSIHANDLE handle, UINT iField, int iVal )
MSIRECORD *rec;
UINT ret;
TRACE("%d %u %d\n", handle, iField, iVal);
TRACE( "%lu, %u, %d\n", handle, iField, iVal );
rec = msihandle2msiinfo( handle, MSIHANDLETYPE_RECORD );
if( !rec )
......@@ -335,7 +335,7 @@ BOOL WINAPI MsiRecordIsNull( MSIHANDLE handle, UINT iField )
MSIRECORD *rec;
UINT ret;
TRACE("%d %d\n", handle, iField );
TRACE( "%lu, %u\n", handle, iField );
rec = msihandle2msiinfo( handle, MSIHANDLETYPE_RECORD );
if( !rec )
......@@ -400,13 +400,12 @@ UINT MSI_RecordGetStringA(MSIRECORD *rec, UINT iField,
return ret;
}
UINT WINAPI MsiRecordGetStringA(MSIHANDLE handle, UINT iField,
LPSTR szValue, LPDWORD pcchValue)
UINT WINAPI MsiRecordGetStringA( MSIHANDLE handle, UINT iField, char *szValue, DWORD *pcchValue )
{
MSIRECORD *rec;
UINT ret;
TRACE("%d %d %p %p\n", handle, iField, szValue, pcchValue);
TRACE( "%lu, %d, %p, %p\n", handle, iField, szValue, pcchValue );
rec = msihandle2msiinfo( handle, MSIHANDLETYPE_RECORD );
if( !rec )
......@@ -436,13 +435,12 @@ const WCHAR *MSI_RecordGetString( const MSIRECORD *rec, UINT iField )
return msi_record_get_string( rec, iField, NULL );
}
UINT MSI_RecordGetStringW(MSIRECORD *rec, UINT iField,
LPWSTR szValue, LPDWORD pcchValue)
UINT MSI_RecordGetStringW( MSIRECORD *rec, UINT iField, WCHAR *szValue, DWORD *pcchValue )
{
UINT len = 0, ret = ERROR_SUCCESS;
WCHAR buffer[16];
TRACE("%p %d %p %p\n", rec, iField, szValue, pcchValue);
TRACE( "%p, %u, %p, %p\n", rec, iField, szValue, pcchValue );
if( iField > rec->count )
{
......@@ -481,13 +479,12 @@ UINT MSI_RecordGetStringW(MSIRECORD *rec, UINT iField,
return ret;
}
UINT WINAPI MsiRecordGetStringW(MSIHANDLE handle, UINT iField,
LPWSTR szValue, LPDWORD pcchValue)
UINT WINAPI MsiRecordGetStringW( MSIHANDLE handle, UINT iField, WCHAR *szValue, DWORD *pcchValue )
{
MSIRECORD *rec;
UINT ret;
TRACE("%d %d %p %p\n", handle, iField, szValue, pcchValue);
TRACE( "%lu, %u, %p, %p\n", handle, iField, szValue, pcchValue );
rec = msihandle2msiinfo( handle, MSIHANDLETYPE_RECORD );
if( !rec )
......@@ -532,12 +529,12 @@ static UINT MSI_RecordDataSize(MSIRECORD *rec, UINT iField)
return 0;
}
UINT WINAPI MsiRecordDataSize(MSIHANDLE handle, UINT iField)
UINT WINAPI MsiRecordDataSize( MSIHANDLE handle, UINT iField )
{
MSIRECORD *rec;
UINT ret;
TRACE("%d %d\n", handle, iField);
TRACE( "%lu, %u\n", handle, iField );
rec = msihandle2msiinfo( handle, MSIHANDLETYPE_RECORD );
if( !rec )
......@@ -549,13 +546,13 @@ UINT WINAPI MsiRecordDataSize(MSIHANDLE handle, UINT iField)
return ret;
}
UINT WINAPI MsiRecordSetStringA( MSIHANDLE handle, UINT iField, LPCSTR szValue )
UINT WINAPI MsiRecordSetStringA( MSIHANDLE handle, UINT iField, const char *szValue )
{
WCHAR *valueW = NULL;
MSIRECORD *rec;
UINT ret;
TRACE("%d %d %s\n", handle, iField, debugstr_a(szValue));
TRACE( "%lu, %u %s\n", handle, iField, debugstr_a(szValue) );
if (szValue && !(valueW = strdupAtoW( szValue ))) return ERROR_OUTOFMEMORY;
......@@ -604,12 +601,12 @@ UINT MSI_RecordSetStringW( MSIRECORD *rec, UINT iField, LPCWSTR szValue )
return msi_record_set_string( rec, iField, szValue, -1 );
}
UINT WINAPI MsiRecordSetStringW( MSIHANDLE handle, UINT iField, LPCWSTR szValue )
UINT WINAPI MsiRecordSetStringW( MSIHANDLE handle, UINT iField, const WCHAR *szValue )
{
MSIRECORD *rec;
UINT ret;
TRACE("%d %d %s\n", handle, iField, debugstr_w(szValue));
TRACE( "%lu, %u, %s\n", handle, iField, debugstr_w(szValue) );
rec = msihandle2msiinfo( handle, MSIHANDLETYPE_RECORD );
if( !rec )
......@@ -667,8 +664,7 @@ static UINT RECORD_StreamFromFile(LPCWSTR szFile, IStream **pstm)
ulSize.QuadPart = sz;
IStream_SetSize(*pstm, ulSize);
TRACE("read %s, %d bytes into IStream %p\n", debugstr_w(szFile), sz, *pstm);
TRACE( "read %s, %lu bytes into IStream %p\n", debugstr_w(szFile), sz, *pstm );
return ERROR_SUCCESS;
}
......@@ -725,12 +721,12 @@ UINT MSI_RecordSetStreamFromFileW(MSIRECORD *rec, UINT iField, LPCWSTR szFilenam
return ERROR_SUCCESS;
}
UINT WINAPI MsiRecordSetStreamA(MSIHANDLE hRecord, UINT iField, LPCSTR szFilename)
UINT WINAPI MsiRecordSetStreamA( MSIHANDLE hRecord, UINT iField, const char *szFilename )
{
LPWSTR wstr = NULL;
WCHAR *wstr = NULL;
UINT ret;
TRACE("%d %d %s\n", hRecord, iField, debugstr_a(szFilename));
TRACE( "%lu, %u, %s\n", hRecord, iField, debugstr_a(szFilename) );
if( szFilename )
{
......@@ -744,12 +740,12 @@ UINT WINAPI MsiRecordSetStreamA(MSIHANDLE hRecord, UINT iField, LPCSTR szFilenam
return ret;
}
UINT WINAPI MsiRecordSetStreamW(MSIHANDLE handle, UINT iField, LPCWSTR szFilename)
UINT WINAPI MsiRecordSetStreamW( MSIHANDLE handle, UINT iField, const WCHAR *szFilename )
{
MSIRECORD *rec;
UINT ret;
TRACE("%d %d %s\n", handle, iField, debugstr_w(szFilename));
TRACE( "%lu, %u, %s\n", handle, iField, debugstr_w(szFilename) );
rec = msihandle2msiinfo( handle, MSIHANDLETYPE_RECORD );
if( !rec )
......@@ -820,12 +816,12 @@ UINT MSI_RecordReadStream(MSIRECORD *rec, UINT iField, char *buf, LPDWORD sz)
return ERROR_SUCCESS;
}
UINT WINAPI MsiRecordReadStream(MSIHANDLE handle, UINT iField, char *buf, LPDWORD sz)
UINT WINAPI MsiRecordReadStream( MSIHANDLE handle, UINT iField, char *buf, DWORD *sz )
{
MSIRECORD *rec;
UINT ret;
TRACE("%d %d %p %p\n", handle, iField, buf, sz);
TRACE( "%lu, %u, %p, %p\n", handle, iField, buf, sz );
rec = msihandle2msiinfo( handle, MSIHANDLETYPE_RECORD );
if( !rec )
......
......@@ -90,7 +90,7 @@ static ULONG WINAPI MsiActiveScriptSite_AddRef(IActiveScriptSite* iface)
{
MsiActiveScriptSite *This = impl_from_IActiveScriptSite(iface);
ULONG ref = InterlockedIncrement(&This->ref);
TRACE("(%p)->(%d)\n", This, ref);
TRACE( "(%p)->(%lu)\n", This, ref );
return ref;
}
......@@ -99,7 +99,7 @@ static ULONG WINAPI MsiActiveScriptSite_Release(IActiveScriptSite* iface)
MsiActiveScriptSite *This = impl_from_IActiveScriptSite(iface);
ULONG ref = InterlockedDecrement(&This->ref);
TRACE("(%p)->(%d)\n", This, ref);
TRACE( "(%p)->(%lu)\n", This, ref );
if (!ref)
msi_free(This);
......@@ -118,7 +118,7 @@ static HRESULT WINAPI MsiActiveScriptSite_GetItemInfo(IActiveScriptSite* iface,
{
MsiActiveScriptSite *This = impl_from_IActiveScriptSite(iface);
TRACE("(%p)->(%p, %d, %p, %p)\n", This, pstrName, dwReturnMask, ppiunkItem, ppti);
TRACE( "(%p)->(%p, %lu, %p, %p)\n", This, pstrName, dwReturnMask, ppiunkItem, ppti );
/* Determine the kind of pointer that is requested, and make sure placeholder is valid */
if (dwReturnMask & SCRIPTINFO_ITYPEINFO) {
......
......@@ -481,7 +481,7 @@ static UINT load_streams( MSIDATABASE *db )
CoTaskMemFree( stat.pwcsName );
if (FAILED( hr ))
{
ERR("unable to open stream %08x\n", hr);
ERR( "unable to open stream %#lx\n", hr );
r = ERROR_FUNCTION_FAILED;
break;
}
......@@ -584,7 +584,7 @@ static HRESULT write_stream( IStream *dst, IStream *src )
hr = IStream_Read( src, buf, size, &count );
if (FAILED( hr ) || count != size)
{
WARN("failed to read stream: %08x\n", hr);
WARN( "failed to read stream: %#lx\n", hr );
return E_INVALIDARG;
}
stat.cbSize.QuadPart -= count;
......@@ -594,7 +594,7 @@ static HRESULT write_stream( IStream *dst, IStream *src )
hr = IStream_Write( dst, buf, size, &count );
if (FAILED( hr ) || count != size)
{
WARN("failed to write stream: %08x\n", hr);
WARN( "failed to write stream: %#lx\n", hr );
return E_INVALIDARG;
}
}
......@@ -628,7 +628,7 @@ UINT msi_commit_streams( MSIDATABASE *db )
hr = write_stream( stream, db->streams[i].stream );
if (FAILED( hr ))
{
ERR("failed to write stream %s (hr = %08x)\n", debugstr_w(encname), hr);
ERR( "failed to write stream %s (hr = %#lx)\n", debugstr_w(encname), hr );
msi_free( encname );
IStream_Release( stream );
return ERROR_FUNCTION_FAILED;
......@@ -637,14 +637,14 @@ UINT msi_commit_streams( MSIDATABASE *db )
IStream_Release( stream );
if (FAILED( hr ))
{
ERR("failed to commit stream %s (hr = %08x)\n", debugstr_w(encname), hr);
ERR( "failed to commit stream %s (hr = %#lx)\n", debugstr_w(encname), hr );
msi_free( encname );
return ERROR_FUNCTION_FAILED;
}
}
else if (hr != STG_E_FILEALREADYEXISTS)
{
ERR("failed to create stream %s (hr = %08x)\n", debugstr_w(encname), hr);
ERR( "failed to create stream %s (hr = %#lx)\n", debugstr_w(encname), hr );
msi_free( encname );
return ERROR_FUNCTION_FAILED;
}
......
......@@ -544,15 +544,15 @@ string_table *msi_load_string_table( IStorage *stg, UINT *bytes_per_strref )
r = add_string( st, n, data+offset, len, refs, TRUE );
if( r != n )
ERR("Failed to add string %d\n", n );
ERR( "Failed to add string %lu\n", n );
n++;
offset += len;
}
if ( datasize != offset )
ERR("string table load failed! (%08x != %08x), please report\n", datasize, offset );
ERR( "string table load failed! (%u != %lu), please report\n", datasize, offset );
TRACE("Loaded %d strings\n", count);
TRACE( "loaded %lu strings\n", count );
end:
msi_free( pool );
......
......@@ -184,14 +184,14 @@ static void read_properties_from_data( PROPVARIANT *prop, LPBYTE data, DWORD sz
{
if( idofs[i].propid >= MSI_MAX_PROPS )
{
ERR("Unknown property ID %d\n", idofs[i].propid );
ERR( "unknown property ID %lu\n", idofs[i].propid );
break;
}
type = get_type( idofs[i].propid );
if( type == VT_EMPTY )
{
ERR("propid %d has unknown type\n", idofs[i].propid);
ERR( "propid %lu has unknown type\n", idofs[i].propid );
break;
}
......@@ -282,7 +282,7 @@ static UINT load_summary_info( MSISUMMARYINFO *si, IStream *stm )
if( section_hdr.cProperties > MSI_MAX_PROPS )
{
ERR("too many properties %d\n", section_hdr.cProperties);
ERR( "too many properties %lu\n", section_hdr.cProperties );
return ERROR_FUNCTION_FAILED;
}
......@@ -298,7 +298,7 @@ static UINT load_summary_info( MSISUMMARYINFO *si, IStream *stm )
if( SUCCEEDED(r) && count == sz )
read_properties_from_data( si->property, data, sz + SECT_HDR_SIZE );
else
ERR("failed to read properties %d %d\n", count, sz);
ERR( "failed to read properties %lu %lu\n", count, sz );
msi_free( data );
return ERROR_SUCCESS;
......@@ -498,15 +498,14 @@ UINT msi_get_db_suminfo( MSIDATABASE *db, UINT uiUpdateCount, MSISUMMARYINFO **r
return ERROR_SUCCESS;
}
UINT WINAPI MsiGetSummaryInformationW( MSIHANDLE hDatabase,
LPCWSTR szDatabase, UINT uiUpdateCount, MSIHANDLE *pHandle )
UINT WINAPI MsiGetSummaryInformationW( MSIHANDLE hDatabase, const WCHAR *szDatabase, UINT uiUpdateCount,
MSIHANDLE *pHandle )
{
MSISUMMARYINFO *si;
MSIDATABASE *db;
UINT ret;
TRACE("%d %s %d %p\n", hDatabase, debugstr_w(szDatabase),
uiUpdateCount, pHandle);
TRACE( "%lu, %s, %u, %p\n", hDatabase, debugstr_w(szDatabase), uiUpdateCount, pHandle );
if( !pHandle )
return ERROR_INVALID_PARAMETER;
......@@ -569,14 +568,13 @@ UINT WINAPI MsiGetSummaryInformationW( MSIHANDLE hDatabase,
return ret;
}
UINT WINAPI MsiGetSummaryInformationA(MSIHANDLE hDatabase,
LPCSTR szDatabase, UINT uiUpdateCount, MSIHANDLE *pHandle)
UINT WINAPI MsiGetSummaryInformationA( MSIHANDLE hDatabase, const char *szDatabase, UINT uiUpdateCount,
MSIHANDLE *pHandle )
{
LPWSTR szwDatabase = NULL;
WCHAR *szwDatabase = NULL;
UINT ret;
TRACE("%d %s %d %p\n", hDatabase, debugstr_a(szDatabase),
uiUpdateCount, pHandle);
TRACE( "%lu, %s, %u, %p\n", hDatabase, debugstr_a(szDatabase), uiUpdateCount, pHandle );
if( szDatabase )
{
......@@ -592,11 +590,11 @@ UINT WINAPI MsiGetSummaryInformationA(MSIHANDLE hDatabase,
return ret;
}
UINT WINAPI MsiSummaryInfoGetPropertyCount(MSIHANDLE hSummaryInfo, PUINT pCount)
UINT WINAPI MsiSummaryInfoGetPropertyCount( MSIHANDLE hSummaryInfo, UINT *pCount )
{
MSISUMMARYINFO *si;
TRACE("%d %p\n", hSummaryInfo, pCount);
TRACE( "%lu, %p\n", hSummaryInfo, pCount );
si = msihandle2msiinfo( hSummaryInfo, MSIHANDLETYPE_SUMMARYINFO );
if( !si )
......@@ -723,16 +721,15 @@ LPWSTR msi_get_suminfo_product( IStorage *stg )
return prod;
}
UINT WINAPI MsiSummaryInfoGetPropertyA(
MSIHANDLE handle, UINT uiProperty, PUINT puiDataType, LPINT piValue,
FILETIME *pftValue, LPSTR szValueBuf, LPDWORD pcchValueBuf)
UINT WINAPI MsiSummaryInfoGetPropertyA( MSIHANDLE handle, UINT uiProperty, UINT *puiDataType, INT *piValue,
FILETIME *pftValue, char *szValueBuf, DWORD *pcchValueBuf )
{
MSISUMMARYINFO *si;
awstring str;
UINT r;
TRACE("%u, %u, %p, %p, %p, %p, %p\n", handle, uiProperty, puiDataType,
piValue, pftValue, szValueBuf, pcchValueBuf );
TRACE( "%lu, %u, %p, %p, %p, %p, %p\n", handle, uiProperty, puiDataType, piValue, pftValue, szValueBuf,
pcchValueBuf );
if (uiProperty >= MSI_MAX_PROPS)
{
......@@ -775,16 +772,15 @@ UINT WINAPI MsiSummaryInfoGetPropertyA(
return r;
}
UINT WINAPI MsiSummaryInfoGetPropertyW(
MSIHANDLE handle, UINT uiProperty, PUINT puiDataType, LPINT piValue,
FILETIME *pftValue, LPWSTR szValueBuf, LPDWORD pcchValueBuf)
UINT WINAPI MsiSummaryInfoGetPropertyW( MSIHANDLE handle, UINT uiProperty, UINT *puiDataType, INT *piValue,
FILETIME *pftValue, WCHAR *szValueBuf, DWORD *pcchValueBuf )
{
MSISUMMARYINFO *si;
awstring str;
UINT r;
TRACE("%u, %u, %p, %p, %p, %p, %p\n", handle, uiProperty, puiDataType,
piValue, pftValue, szValueBuf, pcchValueBuf );
TRACE( "%lu, %u, %p, %p, %p, %p, %p\n", handle, uiProperty, puiDataType, piValue, pftValue, szValueBuf,
pcchValueBuf );
if (uiProperty >= MSI_MAX_PROPS)
{
......@@ -895,15 +891,14 @@ static UINT msi_set_prop( MSISUMMARYINFO *si, UINT uiProperty, UINT uiDataType,
return set_prop( si, uiProperty, type, iValue, pftValue, str );
}
UINT WINAPI MsiSummaryInfoSetPropertyW( MSIHANDLE handle, UINT uiProperty, UINT uiDataType,
INT iValue, FILETIME *pftValue, LPCWSTR szValue )
UINT WINAPI MsiSummaryInfoSetPropertyW( MSIHANDLE handle, UINT uiProperty, UINT uiDataType, INT iValue,
FILETIME *pftValue, const WCHAR *szValue )
{
awcstring str;
MSISUMMARYINFO *si;
UINT ret;
TRACE("%u, %u, %u, %d, %p, %s\n", handle, uiProperty, uiDataType, iValue, pftValue,
debugstr_w(szValue) );
TRACE( "%lu, %u, %u, %d, %p, %s\n", handle, uiProperty, uiDataType, iValue, pftValue, debugstr_w(szValue) );
if (!(si = msihandle2msiinfo( handle, MSIHANDLETYPE_SUMMARYINFO )))
{
......@@ -926,15 +921,14 @@ UINT WINAPI MsiSummaryInfoSetPropertyW( MSIHANDLE handle, UINT uiProperty, UINT
return ret;
}
UINT WINAPI MsiSummaryInfoSetPropertyA( MSIHANDLE handle, UINT uiProperty, UINT uiDataType,
INT iValue, FILETIME *pftValue, LPCSTR szValue )
UINT WINAPI MsiSummaryInfoSetPropertyA( MSIHANDLE handle, UINT uiProperty, UINT uiDataType, INT iValue,
FILETIME *pftValue, const char *szValue )
{
awcstring str;
MSISUMMARYINFO *si;
UINT ret;
TRACE("%u, %u, %u, %d, %p, %s\n", handle, uiProperty, uiDataType, iValue, pftValue,
debugstr_a(szValue) );
TRACE( "%lu, %u, %u, %d, %p, %s\n", handle, uiProperty, uiDataType, iValue, pftValue, debugstr_a(szValue) );
if (!(si = msihandle2msiinfo( handle, MSIHANDLETYPE_SUMMARYINFO )))
{
......@@ -1209,7 +1203,7 @@ UINT WINAPI MsiSummaryInfoPersist( MSIHANDLE handle )
MSISUMMARYINFO *si;
UINT ret;
TRACE("%d\n", handle );
TRACE( "%lu\n", handle );
si = msihandle2msiinfo( handle, MSIHANDLETYPE_SUMMARYINFO );
if( !si )
......@@ -1221,12 +1215,13 @@ UINT WINAPI MsiSummaryInfoPersist( MSIHANDLE handle )
return ret;
}
UINT WINAPI MsiCreateTransformSummaryInfoA( MSIHANDLE db, MSIHANDLE db_ref, LPCSTR transform, int error, int validation )
UINT WINAPI MsiCreateTransformSummaryInfoA( MSIHANDLE db, MSIHANDLE db_ref, const char *transform, int error,
int validation )
{
UINT r;
WCHAR *transformW = NULL;
TRACE("%u, %u, %s, %d, %d\n", db, db_ref, debugstr_a(transform), error, validation);
TRACE( "%lu, %lu, %s, %d, %d\n", db, db_ref, debugstr_a(transform), error, validation );
if (transform && !(transformW = strdupAtoW( transform )))
return ERROR_OUTOFMEMORY;
......@@ -1236,9 +1231,10 @@ UINT WINAPI MsiCreateTransformSummaryInfoA( MSIHANDLE db, MSIHANDLE db_ref, LPCS
return r;
}
UINT WINAPI MsiCreateTransformSummaryInfoW( MSIHANDLE db, MSIHANDLE db_ref, LPCWSTR transform, int error, int validation )
UINT WINAPI MsiCreateTransformSummaryInfoW( MSIHANDLE db, MSIHANDLE db_ref, const WCHAR *transform, int error,
int validation )
{
FIXME("%u, %u, %s, %d, %d\n", db, db_ref, debugstr_w(transform), error, validation);
FIXME( "%lu, %lu, %s, %d, %d\n", db, db_ref, debugstr_w(transform), error, validation );
return ERROR_FUNCTION_FAILED;
}
......
......@@ -221,8 +221,7 @@ void enum_stream_names( IStorage *stg )
if( FAILED( r ) || !count )
break;
decode_streamname( stat.pwcsName, name );
TRACE("stream %2d -> %s %s\n", n,
debugstr_w(stat.pwcsName), debugstr_w(name) );
TRACE( "stream %2lu -> %s %s\n", n, debugstr_w(stat.pwcsName), debugstr_w(name) );
CoTaskMemFree( stat.pwcsName );
n++;
}
......@@ -250,14 +249,14 @@ UINT read_stream_data( IStorage *stg, LPCWSTR stname, BOOL table,
msi_free( encname );
if( FAILED( r ) )
{
WARN("open stream failed r = %08x - empty table?\n", r);
WARN( "open stream failed r = %#lx - empty table?\n", r );
return ret;
}
r = IStream_Stat(stm, &stat, STATFLAG_NONAME );
if( FAILED( r ) )
{
WARN("open stream failed r = %08x!\n", r);
WARN( "open stream failed r = %#lx!\n", r );
goto end;
}
......@@ -271,7 +270,7 @@ UINT read_stream_data( IStorage *stg, LPCWSTR stname, BOOL table,
data = msi_alloc( sz );
if( !data )
{
WARN("couldn't allocate memory r=%08x!\n", r);
WARN( "couldn't allocate memory r = %#lx!\n", r );
ret = ERROR_NOT_ENOUGH_MEMORY;
goto end;
}
......@@ -280,7 +279,7 @@ UINT read_stream_data( IStorage *stg, LPCWSTR stname, BOOL table,
if( FAILED( r ) || ( count != sz ) )
{
msi_free( data );
WARN("read stream failed r = %08x!\n", r);
WARN("read stream failed r = %#lx!\n", r);
goto end;
}
......@@ -316,7 +315,7 @@ UINT write_stream_data( IStorage *stg, LPCWSTR stname,
msi_free( encname );
if( FAILED( r ) )
{
WARN("open stream failed r = %08x\n", r);
WARN( "open stream failed r = %#lx\n", r );
return ret;
}
......@@ -1929,7 +1928,7 @@ static UINT TABLE_add_ref(struct tagMSIVIEW *view)
{
MSITABLEVIEW *tv = (MSITABLEVIEW*)view;
TRACE("%p %d\n", view, tv->table->ref_count);
TRACE( "%p, %ld\n", view, tv->table->ref_count );
return InterlockedIncrement(&tv->table->ref_count);
}
......@@ -2914,7 +2913,7 @@ UINT MSI_CommitTables( MSIDATABASE *db )
hr = IStorage_Commit( db->storage, 0 );
if (FAILED( hr ))
{
WARN("failed to commit changes 0x%08x\n", hr);
WARN( "failed to commit changes %#lx\n", hr );
r = ERROR_FUNCTION_FAILED;
}
return r;
......
......@@ -142,7 +142,7 @@ static UINT ITERATE_FindRelatedProducts(MSIRECORD *rec, LPVOID param)
HKEY hukey;
INT r;
TRACE("Looking at index %u product %s\n", index, debugstr_w(product));
TRACE( "looking at index %lu product %s\n", index, debugstr_w(product) );
unsquash_guid(product, productid);
if (MSIREG_OpenProductKey(productid, NULL, MSIINSTALLCONTEXT_USERMANAGED, &hukey, FALSE) &&
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment