Wine-Devel
By thread
wine-devel@list.winehq.org
By month
Messages by month
- ----- 2026 -----
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2025 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2024 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2023 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2022 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2021 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2020 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2019 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2018 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2017 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2016 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2015 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2014 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2013 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2012 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2011 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2010 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2009 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2008 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2007 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2006 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2005 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2004 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2003 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2002 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
- January
- ----- 2001 -----
- December
- November
- October
- September
- August
- July
- June
- May
- April
- March
- February
January 2022
- 86 participants
- 2418 messages
[PATCH 12/15] programs/msiexec: enable compilation with long types
by Eric Pouech
---
programs/msiexec/Makefile.in | 1 -
programs/msiexec/msiexec.c | 12 ++++++------
programs/msiexec/service.c | 4 ++--
3 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/programs/msiexec/Makefile.in b/programs/msiexec/Makefile.in
index 9aebdbdddf0..e873f7aeaa8 100644
--- a/programs/msiexec/Makefile.in
+++ b/programs/msiexec/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = msiexec.exe
IMPORTS = msi ole32 advapi32 user32 comctl32
diff --git a/programs/msiexec/msiexec.c b/programs/msiexec/msiexec.c
index e9e74f5c19e..71ecc0e590a 100644
--- a/programs/msiexec/msiexec.c
+++ b/programs/msiexec/msiexec.c
@@ -61,13 +61,13 @@ static void ShowUsage(int ExitCode)
*filename = 0;
res = GetModuleFileNameW(hmsi, filename, ARRAY_SIZE(filename));
if (!res)
- WINE_ERR("GetModuleFileName failed: %d\n", GetLastError());
+ WINE_ERR("GetModuleFileName failed: %ld\n", GetLastError());
len = ARRAY_SIZE(msiexec_version);
*msiexec_version = 0;
res = MsiGetFileVersionW(filename, msiexec_version, &len, NULL, NULL);
if (res)
- WINE_ERR("MsiGetFileVersion failed with %d\n", res);
+ WINE_ERR("MsiGetFileVersion failed with %ld\n", res);
/* Return the length of the resource.
No typo: The LPWSTR parameter must be a LPWSTR * for this mode */
@@ -413,7 +413,7 @@ static int custom_action_server(const WCHAR *arg)
pipe = CreateFileW(buffer, GENERIC_READ | GENERIC_WRITE, 0, NULL, OPEN_EXISTING, 0, NULL);
if (pipe == INVALID_HANDLE_VALUE)
{
- ERR("Failed to create custom action server pipe: %u\n", GetLastError());
+ ERR("Failed to create custom action server pipe: %lu\n", GetLastError());
return GetLastError();
}
@@ -438,12 +438,12 @@ static int custom_action_server(const WCHAR *arg)
thread64 = (DWORD_PTR)thread;
if (!WriteFile(pipe, &thread64, sizeof(thread64), &size, NULL) || size != sizeof(thread64))
{
- ERR("Failed to write to custom action server pipe: %u\n", GetLastError());
+ ERR("Failed to write to custom action server pipe: %lu\n", GetLastError());
CoUninitialize();
return GetLastError();
}
}
- ERR("Failed to read from custom action server pipe: %u\n", GetLastError());
+ ERR("Failed to read from custom action server pipe: %lu\n", GetLastError());
CoUninitialize();
return GetLastError();
}
@@ -948,7 +948,7 @@ int WINAPI WinMain(HINSTANCE hInstance, HINSTANCE hPrevInstance, LPSTR lpCmdLine
LogFileName = argvW[i];
if(MsiEnableLogW(LogMode, LogFileName, LogAttributes) != ERROR_SUCCESS)
{
- fprintf(stderr, "Logging in %s (0x%08x, %u) failed\n",
+ fprintf(stderr, "Logging in %s (0x%08lx, %lu) failed\n",
wine_dbgstr_w(LogFileName), LogMode, LogAttributes);
ExitProcess(1);
}
diff --git a/programs/msiexec/service.c b/programs/msiexec/service.c
index 735cd5c0fb0..573b3782473 100644
--- a/programs/msiexec/service.c
+++ b/programs/msiexec/service.c
@@ -83,7 +83,7 @@ static BOOL UpdateSCMStatus(DWORD dwCurrentState, DWORD dwWin32ExitCode,
static void WINAPI ServiceCtrlHandler(DWORD code)
{
- WINE_TRACE("%d\n", code);
+ WINE_TRACE("%ld\n", code);
switch (code)
{
@@ -93,7 +93,7 @@ static void WINAPI ServiceCtrlHandler(DWORD code)
KillService();
break;
default:
- fprintf(stderr, "Unhandled service control code: %d\n", code);
+ fprintf(stderr, "Unhandled service control code: %ld\n", code);
UpdateSCMStatus(SERVICE_RUNNING, NO_ERROR, 0);
break;
}
Jan. 28, 2022
[PATCH 11/15] programs/fsutil: enable compilation with long types
by Eric Pouech
---
programs/fsutil/Makefile.in | 1 -
programs/fsutil/main.c | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/programs/fsutil/Makefile.in b/programs/fsutil/Makefile.in
index 676e9d593dd..df1c8ac6657 100644
--- a/programs/fsutil/Makefile.in
+++ b/programs/fsutil/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = fsutil.exe
IMPORTS = user32
diff --git a/programs/fsutil/main.c b/programs/fsutil/main.c
index 46deda8a51d..94151ae9b42 100644
--- a/programs/fsutil/main.c
+++ b/programs/fsutil/main.c
@@ -59,7 +59,7 @@ static int WINAPIV output_string(int msg, ...)
va_end(arguments);
if (len == 0 && GetLastError() != NO_ERROR)
- WINE_FIXME("Could not format string: le=%u, msg=%d\n", GetLastError(), msg);
+ WINE_FIXME("Could not format string: le=%lu, msg=%d\n", GetLastError(), msg);
else
output_write(out, len);
Jan. 28, 2022
[PATCH 10/15] programs/explorer: enable compilation with long types
by Eric Pouech
---
programs/explorer/Makefile.in | 1 -
programs/explorer/appbar.c | 2 +-
programs/explorer/desktop.c | 52 +++++++++++++++++++++--------------------
programs/explorer/explorer.c | 4 ++-
programs/explorer/systray.c | 2 +-
5 files changed, 30 insertions(+), 31 deletions(-)
diff --git a/programs/explorer/Makefile.in b/programs/explorer/Makefile.in
index 8d5cd94957f..5507d747bb1 100644
--- a/programs/explorer/Makefile.in
+++ b/programs/explorer/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = explorer.exe
IMPORTS = rpcrt4 user32 gdi32 advapi32
DELAYIMPORTS = comctl32 shell32 oleaut32 ole32 shlwapi
diff --git a/programs/explorer/appbar.c b/programs/explorer/appbar.c
index 01dda7ec835..443927e30f1 100644
--- a/programs/explorer/appbar.c
+++ b/programs/explorer/appbar.c
@@ -223,7 +223,7 @@ static UINT_PTR handle_appbarmessage(DWORD msg, struct appbar_data_msg *abd)
case ABM_WINDOWPOSCHANGED:
return TRUE;
default:
- WINE_FIXME("SHAppBarMessage(%x) unimplemented\n", msg);
+ WINE_FIXME("SHAppBarMessage(%lx) unimplemented\n", msg);
return FALSE;
}
}
diff --git a/programs/explorer/desktop.c b/programs/explorer/desktop.c
index 6d577dd0fd1..400cc1d560e 100644
--- a/programs/explorer/desktop.c
+++ b/programs/explorer/desktop.c
@@ -84,7 +84,7 @@ static HRESULT load_typelib(void)
hres = LoadRegTypeLib(&LIBID_SHDocVw, 1, 0, LOCALE_SYSTEM_DEFAULT, &tl);
if (FAILED(hres))
{
- ERR("LoadRegTypeLib failed: %08x\n", hres);
+ ERR("LoadRegTypeLib failed: %08lx\n", hres);
return hres;
}
@@ -107,7 +107,7 @@ static HRESULT get_typeinfo(tid_t tid, ITypeInfo **typeinfo)
hres = ITypeLib_GetTypeInfoOfGuid(typelib, tid_ids[tid], &ti);
if (FAILED(hres)) {
- ERR("GetTypeInfoOfGuid(%s) failed: %08x\n", debugstr_guid(tid_ids[tid]), hres);
+ ERR("GetTypeInfoOfGuid(%s) failed: %08lx\n", debugstr_guid(tid_ids[tid]), hres);
return hres;
}
@@ -467,7 +467,7 @@ static BOOL process_changes( const WCHAR *folder, char *buf )
break;
default:
- WARN( "unexpected action %u\n", info->Action );
+ WARN( "unexpected action %lu\n", info->Action );
break;
}
if (!info->NextEntryOffset) break;
@@ -623,7 +623,7 @@ static WNDPROC desktop_orig_wndproc;
/* window procedure for the desktop window */
static LRESULT WINAPI desktop_wnd_proc( HWND hwnd, UINT message, WPARAM wp, LPARAM lp )
{
- WINE_TRACE( "got msg %04x wp %lx lp %lx\n", message, wp, lp );
+ WINE_TRACE( "got msg %04x wp %Ix lp %Ix\n", message, wp, lp );
switch(message)
{
@@ -852,7 +852,7 @@ static HMODULE load_graphics_driver( const WCHAR *driver, const GUID *guid )
strcpy( error, "Make sure that your X server is running and that $DISPLAY is set correctly." );
break;
default:
- sprintf( error, "Unknown error (%u).", GetLastError() );
+ sprintf( error, "Unknown error (%lu).", GetLastError() );
break;
}
name = next;
@@ -897,7 +897,7 @@ static void initialize_display_settings(void)
continue;
}
- WINE_TRACE( "Device %s current display mode %ux%u %uBits %uHz at %d,%d.\n",
+ WINE_TRACE( "Device %s current display mode %lux%lu %luBits %luHz at %ld,%ld.\n",
wine_dbgstr_w( ddW.DeviceName ), dmW.dmPelsWidth, dmW.dmPelsHeight,
dmW.dmBitsPerPel, dmW.dmDisplayFrequency, dmW.u1.s2.dmPosition.x,
dmW.u1.s2.dmPosition.y );
@@ -997,7 +997,7 @@ void manage_desktop( WCHAR *arg )
{
if (!(desktop = CreateDesktopW( name, NULL, NULL, 0, DESKTOP_ALL_ACCESS, NULL )))
{
- WINE_ERR( "failed to create desktop %s error %d\n", wine_dbgstr_w(name), GetLastError() );
+ WINE_ERR( "failed to create desktop %s error %ld\n", wine_dbgstr_w(name), GetLastError() );
ExitProcess( 1 );
}
SetThreadDesktop( desktop );
@@ -1122,7 +1122,7 @@ static HRESULT WINAPI shellwindows_GetTypeInfoCount(IShellWindows *iface, UINT *
static HRESULT WINAPI shellwindows_GetTypeInfo(IShellWindows *iface,
UINT iTInfo, LCID lcid, ITypeInfo **ppTInfo)
{
- TRACE("%d %d %p\n", iTInfo, lcid, ppTInfo);
+ TRACE("%d %ld %p\n", iTInfo, lcid, ppTInfo);
return get_typeinfo(IShellWindows_tid, ppTInfo);
}
@@ -1133,7 +1133,7 @@ static HRESULT WINAPI shellwindows_GetIDsOfNames(IShellWindows *iface,
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("%s %p %d %d %p\n", debugstr_guid(riid), rgszNames, cNames,
+ TRACE("%s %p %d %ld %p\n", debugstr_guid(riid), rgszNames, cNames,
lcid, rgDispId);
if (!rgszNames || cNames == 0 || !rgDispId)
@@ -1157,7 +1157,7 @@ static HRESULT WINAPI shellwindows_Invoke(IShellWindows *iface,
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("%d %s %d %08x %p %p %p %p\n", dispIdMember, debugstr_guid(riid),
+ TRACE("%ld %s %ld %08x %p %p %p %p\n", dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IShellWindows_tid, &typeinfo);
@@ -1196,7 +1196,7 @@ static HRESULT WINAPI shellwindows_Register(IShellWindows *iface,
struct shellwindows *sw = impl_from_IShellWindows(iface);
struct window *window;
- TRACE("iface %p, disp %p, hwnd %#x, class %u, cookie %p.\n", iface, disp, hwnd, class, cookie);
+ TRACE("iface %p, disp %p, hwnd %#lx, class %u, cookie %p.\n", iface, disp, hwnd, class, cookie);
if (!hwnd)
return E_POINTER;
@@ -1225,7 +1225,7 @@ static HRESULT WINAPI shellwindows_Register(IShellWindows *iface,
static HRESULT WINAPI shellwindows_RegisterPending(IShellWindows *iface,
LONG threadid, VARIANT *loc, VARIANT *root, int class, LONG *cookie)
{
- FIXME("0x%x %s %s 0x%x %p\n", threadid, debugstr_variant(loc), debugstr_variant(root),
+ FIXME("0x%lx %s %s 0x%x %p\n", threadid, debugstr_variant(loc), debugstr_variant(root),
class, cookie);
return E_NOTIMPL;
}
@@ -1235,7 +1235,7 @@ static HRESULT WINAPI shellwindows_Revoke(IShellWindows *iface, LONG cookie)
struct shellwindows *sw = impl_from_IShellWindows(iface);
unsigned int i;
- TRACE("iface %p, cookie %u.\n", iface, cookie);
+ TRACE("iface %p, cookie %lu.\n", iface, cookie);
EnterCriticalSection(&sw->cs);
@@ -1259,7 +1259,7 @@ static HRESULT WINAPI shellwindows_OnNavigate(IShellWindows *iface, LONG cookie,
struct shellwindows *sw = impl_from_IShellWindows(iface);
unsigned int i;
- TRACE("iface %p, cookie %u, location %s.\n", iface, cookie, debugstr_variant(location));
+ TRACE("iface %p, cookie %lu, location %s.\n", iface, cookie, debugstr_variant(location));
if (V_VT(location) != (VT_ARRAY | VT_UI1))
{
@@ -1292,7 +1292,7 @@ static HRESULT WINAPI shellwindows_OnNavigate(IShellWindows *iface, LONG cookie,
static HRESULT WINAPI shellwindows_OnActivated(IShellWindows *iface, LONG cookie, VARIANT_BOOL active)
{
- FIXME("0x%x 0x%x\n", cookie, active);
+ FIXME("0x%lx 0x%x\n", cookie, active);
return E_NOTIMPL;
}
@@ -1343,7 +1343,7 @@ static HRESULT WINAPI shellwindows_FindWindowSW(IShellWindows *iface, VARIANT *l
static HRESULT WINAPI shellwindows_OnCreated(IShellWindows *iface, LONG cookie, IUnknown *punk)
{
- FIXME("0x%x %p\n", cookie, punk);
+ FIXME("0x%lx %p\n", cookie, punk);
return E_NOTIMPL;
}
@@ -1497,7 +1497,7 @@ static HRESULT WINAPI webbrowser_GetTypeInfo(IWebBrowser2 *iface, UINT iTInfo, L
LPTYPEINFO *ppTInfo)
{
struct shellbrowserwindow *This = impl_from_IWebBrowser2(iface);
- TRACE("(%p)->(%d %d %p)\n", This, iTInfo, lcid, ppTInfo);
+ TRACE("(%p)->(%d %ld %p)\n", This, iTInfo, lcid, ppTInfo);
return get_typeinfo(IWebBrowser2_tid, ppTInfo);
}
@@ -1509,7 +1509,7 @@ static HRESULT WINAPI webbrowser_GetIDsOfNames(IWebBrowser2 *iface, REFIID riid,
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%s %p %d %d %p)\n", This, debugstr_guid(riid), rgszNames, cNames,
+ TRACE("(%p)->(%s %p %d %ld %p)\n", This, debugstr_guid(riid), rgszNames, cNames,
lcid, rgDispId);
if(!rgszNames || cNames == 0 || !rgDispId)
@@ -1534,7 +1534,7 @@ static HRESULT WINAPI webbrowser_Invoke(IWebBrowser2 *iface, DISPID dispIdMember
ITypeInfo *typeinfo;
HRESULT hr;
- TRACE("(%p)->(%d %s %d %08x %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
+ TRACE("(%p)->(%ld %s %ld %08x %p %p %p %p)\n", This, dispIdMember, debugstr_guid(riid),
lcid, wFlags, pDispParams, pVarResult, pExcepInfo, puArgErr);
hr = get_typeinfo(IWebBrowser2_tid, &typeinfo);
@@ -1666,7 +1666,7 @@ static HRESULT WINAPI webbrowser_get_Left(IWebBrowser2 *iface, LONG *pl)
static HRESULT WINAPI webbrowser_put_Left(IWebBrowser2 *iface, LONG Left)
{
struct shellbrowserwindow *This = impl_from_IWebBrowser2(iface);
- FIXME("(%p)->(%d)\n", This, Left);
+ FIXME("(%p)->(%ld)\n", This, Left);
return E_NOTIMPL;
}
@@ -1680,7 +1680,7 @@ static HRESULT WINAPI webbrowser_get_Top(IWebBrowser2 *iface, LONG *pl)
static HRESULT WINAPI webbrowser_put_Top(IWebBrowser2 *iface, LONG Top)
{
struct shellbrowserwindow *This = impl_from_IWebBrowser2(iface);
- FIXME("(%p)->(%d)\n", This, Top);
+ FIXME("(%p)->(%ld)\n", This, Top);
return E_NOTIMPL;
}
@@ -1694,7 +1694,7 @@ static HRESULT WINAPI webbrowser_get_Width(IWebBrowser2 *iface, LONG *pl)
static HRESULT WINAPI webbrowser_put_Width(IWebBrowser2 *iface, LONG Width)
{
struct shellbrowserwindow *This = impl_from_IWebBrowser2(iface);
- FIXME("(%p)->(%d)\n", This, Width);
+ FIXME("(%p)->(%ld)\n", This, Width);
return E_NOTIMPL;
}
@@ -1708,7 +1708,7 @@ static HRESULT WINAPI webbrowser_get_Height(IWebBrowser2 *iface, LONG *pl)
static HRESULT WINAPI webbrowser_put_Height(IWebBrowser2 *iface, LONG Height)
{
struct shellbrowserwindow *This = impl_from_IWebBrowser2(iface);
- FIXME("(%p)->(%d)\n", This, Height);
+ FIXME("(%p)->(%ld)\n", This, Height);
return E_NOTIMPL;
}
@@ -2223,7 +2223,7 @@ static HRESULT WINAPI shellbrowser_BrowseObject(IShellBrowser *iface, LPCITEMIDL
static HRESULT WINAPI shellbrowser_GetViewStateStream(IShellBrowser *iface, DWORD mode, IStream **stream)
{
- FIXME("0x%x %p\n", mode, stream);
+ FIXME("0x%lx %p\n", mode, stream);
return E_NOTIMPL;
}
@@ -2236,7 +2236,7 @@ static HRESULT WINAPI shellbrowser_GetControlWindow(IShellBrowser *iface, UINT i
static HRESULT WINAPI shellbrowser_SendControlMsg(IShellBrowser *iface, UINT id, UINT uMsg,
WPARAM wParam, LPARAM lParam, LRESULT *pret)
{
- FIXME("%d %d %lx %lx %p\n", id, uMsg, wParam, lParam, pret);
+ FIXME("%d %d %Ix %Ix %p\n", id, uMsg, wParam, lParam, pret);
return E_NOTIMPL;
}
@@ -2314,5 +2314,5 @@ static void shellwindows_init(void)
&shellwindows_classfactory.classreg);
if (FAILED(hr))
- WARN("Failed to register ShellWindows object: %08x\n", hr);
+ WARN("Failed to register ShellWindows object: %08lx\n", hr);
}
diff --git a/programs/explorer/explorer.c b/programs/explorer/explorer.c
index cb0d63fb688..8aab7fdc5f1 100644
--- a/programs/explorer/explorer.c
+++ b/programs/explorer/explorer.c
@@ -421,7 +421,7 @@ static void make_explorer_window(parameters_struct *params)
V_VT(&empty_var) = VT_EMPTY;
if (IShellWindows_FindWindowSW(sw, &var, &empty_var, SWC_EXPLORER, &hwnd, 0, &dispatch) == S_OK)
{
- TRACE("Found window %#x already browsing path %s.\n", hwnd, debugstr_w(path));
+ TRACE("Found window %#lx already browsing path %s.\n", hwnd, debugstr_w(path));
SetForegroundWindow((HWND)(LONG_PTR)hwnd);
IShellWindows_Release(sw);
return;
@@ -665,7 +665,7 @@ static LRESULT CALLBACK explorer_wnd_proc(HWND hwnd, UINT uMsg, WPARAM wParam, L
= (explorer_info*)GetWindowLongPtrW(hwnd,EXPLORER_INFO_INDEX);
IExplorerBrowser *browser = NULL;
- WINE_TRACE("(hwnd=%p,uMsg=%u,wParam=%lx,lParam=%lx)\n",hwnd,uMsg,wParam,lParam);
+ WINE_TRACE("(hwnd=%p,uMsg=%u,wParam=%Ix,lParam=%Ix)\n",hwnd,uMsg,wParam,lParam);
if(info)
browser = info->browser;
switch(uMsg)
diff --git a/programs/explorer/systray.c b/programs/explorer/systray.c
index 0c978451151..5b7216b2904 100644
--- a/programs/explorer/systray.c
+++ b/programs/explorer/systray.c
@@ -594,7 +594,7 @@ static BOOL handle_incoming(HWND hwndSource, COPYDATASTRUCT *cds)
}
break;
default:
- WINE_FIXME("unhandled tray message: %ld\n", cds->dwData);
+ WINE_FIXME("unhandled tray message: %Id\n", cds->dwData);
break;
}
Jan. 28, 2022
[PATCH 09/15] programs/eject: enable compilation with long types
by Eric Pouech
---
programs/eject/Makefile.in | 1 -
programs/eject/eject.c | 6 +++---
2 files changed, 3 insertions(+), 4 deletions(-)
diff --git a/programs/eject/Makefile.in b/programs/eject/Makefile.in
index 86704201c2b..76274f66d97 100644
--- a/programs/eject/Makefile.in
+++ b/programs/eject/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = eject.exe
EXTRADLLFLAGS = -mconsole
diff --git a/programs/eject/eject.c b/programs/eject/eject.c
index e6416eacff7..718848bccdb 100644
--- a/programs/eject/eject.c
+++ b/programs/eject/eject.c
@@ -70,16 +70,16 @@ static BOOL eject_cd( WCHAR drive )
WINE_TRACE( "ejecting %c:\n", (char)drive );
if (!DeviceIoControl( handle, FSCTL_DISMOUNT_VOLUME, NULL, 0, NULL, 0, &result, NULL ))
- WINE_WARN( "FSCTL_DISMOUNT_VOLUME failed with err %d\n", GetLastError() );
+ WINE_WARN( "FSCTL_DISMOUNT_VOLUME failed with err %ld\n", GetLastError() );
removal.PreventMediaRemoval = FALSE;
if (!DeviceIoControl( handle, IOCTL_STORAGE_MEDIA_REMOVAL, &removal, sizeof(removal), NULL, 0, &result, NULL ))
- WINE_WARN( "IOCTL_STORAGE_MEDIA_REMOVAL failed with err %d\n", GetLastError() );
+ WINE_WARN( "IOCTL_STORAGE_MEDIA_REMOVAL failed with err %ld\n", GetLastError() );
if (!unmount_only)
{
if (!DeviceIoControl( handle, IOCTL_STORAGE_EJECT_MEDIA, NULL, 0, NULL, 0, &result, NULL ))
- WINE_WARN( "IOCTL_STORAGE_EJECT_MEDIA failed with err %d\n", GetLastError() );
+ WINE_WARN( "IOCTL_STORAGE_EJECT_MEDIA failed with err %ld\n", GetLastError() );
}
CloseHandle( handle );
Jan. 28, 2022
[PATCH 08/15] programs/dxdiag: enable compilation with long types
by Eric Pouech
---
programs/dxdiag/Makefile.in | 1 -
programs/dxdiag/information.c | 2 +-
programs/dxdiag/output.c | 6 +++---
3 files changed, 4 insertions(+), 5 deletions(-)
diff --git a/programs/dxdiag/Makefile.in b/programs/dxdiag/Makefile.in
index 9f2f0f19b14..2ea7a084d19 100644
--- a/programs/dxdiag/Makefile.in
+++ b/programs/dxdiag/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = dxdiag.exe
IMPORTS = dxguid ole32 oleaut32 user32 comctl32
diff --git a/programs/dxdiag/information.c b/programs/dxdiag/information.c
index 74fe15f7aec..99c1a6715b2 100644
--- a/programs/dxdiag/information.c
+++ b/programs/dxdiag/information.c
@@ -190,7 +190,7 @@ struct dxdiag_information *collect_dxdiag_information(BOOL whql_check)
&IID_IDxDiagProvider, (void **)&pddp);
if (FAILED(hr))
{
- WINE_ERR("IDxDiagProvider instance creation failed with 0x%08x\n", hr);
+ WINE_ERR("IDxDiagProvider instance creation failed with 0x%08lx\n", hr);
goto error;
}
diff --git a/programs/dxdiag/output.c b/programs/dxdiag/output.c
index 95941785c1c..a8eb733ba4b 100644
--- a/programs/dxdiag/output.c
+++ b/programs/dxdiag/output.c
@@ -85,7 +85,7 @@ static BOOL output_text_field(HANDLE hFile, const char *field_name, DWORD field_
assert(total_len <= sizeof(output_buffer));
- sprintf(sprintf_fmt, "%%%us: ", field_width);
+ sprintf(sprintf_fmt, "%%%lus: ", field_width);
ptr += sprintf(ptr, sprintf_fmt, field_name);
ptr += WideCharToMultiByte(CP_ACP, 0, value, value_lenW, ptr, value_lenA, NULL, NULL);
@@ -153,7 +153,7 @@ static BOOL output_text_information(struct dxdiag_information *dxdiag_info, cons
NULL, CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL);
if (hFile == INVALID_HANDLE_VALUE)
{
- WINE_ERR("File creation failed, last error %u\n", GetLastError());
+ WINE_ERR("File creation failed, last error %lu\n", GetLastError());
return FALSE;
}
@@ -277,7 +277,7 @@ static BOOL output_xml_information(struct dxdiag_information *dxdiag_info, const
&IID_IXMLDOMDocument, (void **)&xmldoc);
if (FAILED(hr))
{
- WINE_ERR("IXMLDOMDocument instance creation failed with 0x%08x\n", hr);
+ WINE_ERR("IXMLDOMDocument instance creation failed with 0x%08lx\n", hr);
goto error;
}
Jan. 28, 2022
[PATCH 07/15] programs/[cw]script: enable compilation with long types
by Eric Pouech
---
programs/cscript/Makefile.in | 2 +-
programs/wscript/Makefile.in | 1 -
programs/wscript/arguments.c | 8 ++++----
programs/wscript/host.c | 10 +++++-----
programs/wscript/main.c | 6 +++---
5 files changed, 13 insertions(+), 14 deletions(-)
diff --git a/programs/cscript/Makefile.in b/programs/cscript/Makefile.in
index 2795a66eeca..d87a28fcc54 100644
--- a/programs/cscript/Makefile.in
+++ b/programs/cscript/Makefile.in
@@ -1,6 +1,6 @@
MODULE = cscript.exe
IMPORTS = uuid shell32 oleaut32 ole32 user32 advapi32
-EXTRADEFS = -DWINE_NO_LONG_TYPES -DCSCRIPT_BUILD
+EXTRADEFS = -DCSCRIPT_BUILD
PARENTSRC = ../wscript
EXTRADLLFLAGS = -mwindows -municode
diff --git a/programs/wscript/Makefile.in b/programs/wscript/Makefile.in
index 77d276d6c01..33b2e66d9bc 100644
--- a/programs/wscript/Makefile.in
+++ b/programs/wscript/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = wscript.exe
IMPORTS = uuid shell32 oleaut32 ole32 user32 advapi32
diff --git a/programs/wscript/arguments.c b/programs/wscript/arguments.c
index 7961948b6a5..a97752f8452 100644
--- a/programs/wscript/arguments.c
+++ b/programs/wscript/arguments.c
@@ -70,7 +70,7 @@ static HRESULT WINAPI Arguments2_GetTypeInfoCount(IArguments2 *iface, UINT *pcti
static HRESULT WINAPI Arguments2_GetTypeInfo(IArguments2 *iface, UINT iTInfo, LCID lcid,
ITypeInfo **ppTInfo)
{
- WINE_TRACE("(%x %x %p\n", iTInfo, lcid, ppTInfo);
+ WINE_TRACE("(%x %lx %p\n", iTInfo, lcid, ppTInfo);
ITypeInfo_AddRef(arguments_ti);
*ppTInfo = arguments_ti;
@@ -80,7 +80,7 @@ static HRESULT WINAPI Arguments2_GetTypeInfo(IArguments2 *iface, UINT iTInfo, LC
static HRESULT WINAPI Arguments2_GetIDsOfNames(IArguments2 *iface, REFIID riid, LPOLESTR *rgszNames,
UINT cNames, LCID lcid, DISPID *rgDispId)
{
- WINE_TRACE("(%s %p %d %x %p)\n", wine_dbgstr_guid(riid), rgszNames,
+ WINE_TRACE("(%s %p %d %lx %p)\n", wine_dbgstr_guid(riid), rgszNames,
cNames, lcid, rgDispId);
return ITypeInfo_GetIDsOfNames(arguments_ti, rgszNames, cNames, rgDispId);
@@ -90,7 +90,7 @@ static HRESULT WINAPI Arguments2_Invoke(IArguments2 *iface, DISPID dispIdMember,
LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult,
EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- WINE_TRACE("(%d %p %p)\n", dispIdMember, pDispParams, pVarResult);
+ WINE_TRACE("(%ld %p %p)\n", dispIdMember, pDispParams, pVarResult);
return ITypeInfo_Invoke(arguments_ti, iface, dispIdMember, wFlags, pDispParams,
pVarResult, pExcepInfo, puArgErr);
@@ -98,7 +98,7 @@ static HRESULT WINAPI Arguments2_Invoke(IArguments2 *iface, DISPID dispIdMember,
static HRESULT WINAPI Arguments2_Item(IArguments2 *iface, LONG index, BSTR *out_Value)
{
- WINE_TRACE("(%d %p)\n", index, out_Value);
+ WINE_TRACE("(%ld %p)\n", index, out_Value);
if(index<0 || index >= numOfArgs)
return E_INVALIDARG;
diff --git a/programs/wscript/host.c b/programs/wscript/host.c
index 8765dd271f4..bd16b7b4cbe 100644
--- a/programs/wscript/host.c
+++ b/programs/wscript/host.c
@@ -126,7 +126,7 @@ static HRESULT WINAPI Host_GetTypeInfoCount(IHost *iface, UINT *pctinfo)
static HRESULT WINAPI Host_GetTypeInfo(IHost *iface, UINT iTInfo, LCID lcid,
ITypeInfo **ppTInfo)
{
- WINE_TRACE("(%x %x %p\n", iTInfo, lcid, ppTInfo);
+ WINE_TRACE("(%x %lx %p\n", iTInfo, lcid, ppTInfo);
ITypeInfo_AddRef(host_ti);
*ppTInfo = host_ti;
@@ -136,7 +136,7 @@ static HRESULT WINAPI Host_GetTypeInfo(IHost *iface, UINT iTInfo, LCID lcid,
static HRESULT WINAPI Host_GetIDsOfNames(IHost *iface, REFIID riid, LPOLESTR *rgszNames,
UINT cNames, LCID lcid, DISPID *rgDispId)
{
- WINE_TRACE("(%s %p %d %x %p)\n", wine_dbgstr_guid(riid), rgszNames,
+ WINE_TRACE("(%s %p %d %lx %p)\n", wine_dbgstr_guid(riid), rgszNames,
cNames, lcid, rgDispId);
return ITypeInfo_GetIDsOfNames(host_ti, rgszNames, cNames, rgDispId);
@@ -146,7 +146,7 @@ static HRESULT WINAPI Host_Invoke(IHost *iface, DISPID dispIdMember, REFIID riid
LCID lcid, WORD wFlags, DISPPARAMS *pDispParams, VARIANT *pVarResult,
EXCEPINFO *pExcepInfo, UINT *puArgErr)
{
- WINE_TRACE("(%d %p %p)\n", dispIdMember, pDispParams, pVarResult);
+ WINE_TRACE("(%ld %p %p)\n", dispIdMember, pDispParams, pVarResult);
return ITypeInfo_Invoke(host_ti, iface, dispIdMember, wFlags, pDispParams,
pVarResult, pExcepInfo, puArgErr);
@@ -278,7 +278,7 @@ static HRESULT WINAPI Host_get_Timeout(IHost *iface, LONG *out_Timeout)
static HRESULT WINAPI Host_put_Timeout(IHost *iface, LONG v)
{
- WINE_FIXME("(%d)\n", v);
+ WINE_FIXME("(%ld)\n", v);
return E_NOTIMPL;
}
@@ -396,7 +396,7 @@ static HRESULT WINAPI Host_DisconnectObject(IHost *iface, IDispatch *Object)
static HRESULT WINAPI Host_Sleep(IHost *iface, LONG Time)
{
- WINE_FIXME("(%d)\n", Time);
+ WINE_FIXME("(%ld)\n", Time);
return E_NOTIMPL;
}
diff --git a/programs/wscript/main.c b/programs/wscript/main.c
index a7005a9289c..12571181491 100644
--- a/programs/wscript/main.c
+++ b/programs/wscript/main.c
@@ -81,7 +81,7 @@ static HRESULT WINAPI ActiveScriptSite_GetLCID(IActiveScriptSite *iface, LCID *p
static HRESULT WINAPI ActiveScriptSite_GetItemInfo(IActiveScriptSite *iface,
LPCOLESTR pstrName, DWORD dwReturnMask, IUnknown **ppunkItem, ITypeInfo **ppti)
{
- WINE_TRACE("(%s %x %p %p)\n", wine_dbgstr_w(pstrName), dwReturnMask, ppunkItem, ppti);
+ WINE_TRACE("(%s %lx %p %p)\n", wine_dbgstr_w(pstrName), dwReturnMask, ppunkItem, ppti);
if(lstrcmpW(pstrName, L"WSH") && lstrcmpW(pstrName, L"WScript"))
return E_FAIL;
@@ -368,13 +368,13 @@ static void run_script(const WCHAR *filename, IActiveScript *script, IActiveScri
SCRIPTTEXT_HOSTMANAGESSOURCE|SCRIPTITEM_ISVISIBLE, NULL, NULL);
SysFreeString(text);
if(FAILED(hres)) {
- WINE_FIXME("ParseScriptText failed: %08x\n", hres);
+ WINE_FIXME("ParseScriptText failed: %08lx\n", hres);
return;
}
hres = IActiveScript_SetScriptState(script, SCRIPTSTATE_STARTED);
if(FAILED(hres))
- WINE_FIXME("SetScriptState failed: %08x\n", hres);
+ WINE_FIXME("SetScriptState failed: %08lx\n", hres);
}
static BOOL set_host_properties(const WCHAR *prop)
Jan. 28, 2022
[PATCH 06/15] programs/conhost: enable compilation with long types
by Eric Pouech
---
programs/conhost/Makefile.in | 1 -
programs/conhost/conhost.c | 18 +++++++++---------
programs/conhost/window.c | 10 +++++-----
3 files changed, 14 insertions(+), 15 deletions(-)
diff --git a/programs/conhost/Makefile.in b/programs/conhost/Makefile.in
index 69559c668ad..2a407006697 100644
--- a/programs/conhost/Makefile.in
+++ b/programs/conhost/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = conhost.exe
IMPORTS = user32 gdi32 advapi32
DELAYIMPORTS = comctl32
diff --git a/programs/conhost/conhost.c b/programs/conhost/conhost.c
index 78f6e345170..52363f72aac 100644
--- a/programs/conhost/conhost.c
+++ b/programs/conhost/conhost.c
@@ -158,7 +158,7 @@ static void tty_flush( struct console *console )
TRACE("%s\n", debugstr_an(console->tty_buffer, console->tty_buffer_count));
if (!WriteFile( console->tty_output, console->tty_buffer, console->tty_buffer_count,
NULL, NULL ))
- WARN( "write failed: %u\n", GetLastError() );
+ WARN( "write failed: %lu\n", GetLastError() );
console->tty_buffer_count = 0;
}
@@ -176,7 +176,7 @@ static void tty_write( struct console *console, const char *buffer, size_t size
{
assert( !console->tty_buffer_count );
if (!WriteFile( console->tty_output, buffer, size, NULL, NULL ))
- WARN( "write failed: %u\n", GetLastError() );
+ WARN( "write failed: %lu\n", GetLastError() );
}
}
@@ -457,7 +457,7 @@ static NTSTATUS read_complete( struct console *console, NTSTATUS status, const v
status = wine_server_call( req );
}
SERVER_END_REQ;
- if (status && (console->read_ioctl || status != STATUS_INVALID_HANDLE)) ERR( "failed: %#x\n", status );
+ if (status && (console->read_ioctl || status != STATUS_INVALID_HANDLE)) ERR( "failed: %#lx\n", status );
console->signaled = signal;
console->read_ioctl = 0;
console->pending_read = 0;
@@ -468,7 +468,7 @@ static NTSTATUS read_console_input( struct console *console, size_t out_size )
{
size_t count = min( out_size / sizeof(INPUT_RECORD), console->record_count );
- TRACE("count %u\n", count);
+ TRACE("count %Iu\n", count);
read_complete( console, STATUS_SUCCESS, console->records, count * sizeof(*console->records),
console->record_count > count );
@@ -1267,7 +1267,7 @@ static NTSTATUS process_console_input( struct console *console )
if (ir.EventType != KEY_EVENT || !ir.Event.KeyEvent.bKeyDown) continue;
- TRACE( "key code=%02x scan=%02x char=%02x state=%08x\n",
+ TRACE( "key code=%02x scan=%02x char=%02x state=%08lx\n",
ir.Event.KeyEvent.wVirtualKeyCode, ir.Event.KeyEvent.wVirtualScanCode,
ir.Event.KeyEvent.uChar.UnicodeChar, ir.Event.KeyEvent.dwControlKeyState );
@@ -1634,7 +1634,7 @@ static DWORD WINAPI tty_input( void *param )
unsigned int h = condrv_handle( console->tty_input );
status = NtDeviceIoControlFile( console->server, NULL, NULL, NULL, &io, IOCTL_CONDRV_SETUP_INPUT,
&h, sizeof(h), NULL, 0 );
- if (status) ERR( "input setup failed: %#x\n", status );
+ if (status) ERR( "input setup failed: %#lx\n", status );
}
event = CreateEventW( NULL, TRUE, FALSE, NULL );
@@ -1691,7 +1691,7 @@ static DWORD WINAPI tty_input( void *param )
LeaveCriticalSection( &console_section );
}
- TRACE( "NtReadFile failed: %#x\n", status );
+ TRACE( "NtReadFile failed: %#lx\n", status );
done:
EnterCriticalSection( &console_section );
@@ -1701,7 +1701,7 @@ done:
unsigned int h = 0;
status = NtDeviceIoControlFile( console->server, NULL, NULL, NULL, &io, IOCTL_CONDRV_SETUP_INPUT,
&h, sizeof(h), NULL, 0 );
- if (status) ERR( "input restore failed: %#x\n", status );
+ if (status) ERR( "input restore failed: %#lx\n", status );
}
CloseHandle( console->input_thread );
console->input_thread = NULL;
@@ -2628,7 +2628,7 @@ static NTSTATUS process_console_ioctls( struct console *console )
}
if (status)
{
- TRACE( "failed to get next request: %#x\n", status );
+ TRACE( "failed to get next request: %#lx\n", status );
return status;
}
diff --git a/programs/conhost/window.c b/programs/conhost/window.c
index 7ad0d48effd..db04ba120e4 100644
--- a/programs/conhost/window.c
+++ b/programs/conhost/window.c
@@ -110,8 +110,8 @@ static const char *debugstr_config( const struct console_config *config )
static const char *debugstr_logfont( const LOGFONTW *lf, unsigned int ft )
{
- return wine_dbg_sprintf( "%s%s%s%s lfHeight=%d lfWidth=%d lfEscapement=%d "
- "lfOrientation=%d lfWeight=%d lfItalic=%u lfUnderline=%u "
+ return wine_dbg_sprintf( "%s%s%s%s lfHeight=%ld lfWidth=%ld lfEscapement=%ld "
+ "lfOrientation=%ld lfWeight=%ld lfItalic=%u lfUnderline=%u "
"lfStrikeOut=%u lfCharSet=%u lfPitchAndFamily=%u lfFaceName=%s",
(ft & RASTER_FONTTYPE) ? "raster" : "",
(ft & TRUETYPE_FONTTYPE) ? "truetype" : "",
@@ -124,8 +124,8 @@ static const char *debugstr_logfont( const LOGFONTW *lf, unsigned int ft )
static const char *debugstr_textmetric( const TEXTMETRICW *tm, unsigned int ft )
{
- return wine_dbg_sprintf( "%s%s%s%s tmHeight=%d tmAscent=%d tmDescent=%d "
- "tmAveCharWidth=%d tmMaxCharWidth=%d tmWeight=%d "
+ return wine_dbg_sprintf( "%s%s%s%s tmHeight=%ld tmAscent=%ld tmDescent=%ld "
+ "tmAveCharWidth=%ld tmMaxCharWidth=%ld tmWeight=%ld "
"tmPitchAndFamily=%u tmCharSet=%u",
(ft & RASTER_FONTTYPE) ? "raster" : "",
(ft & TRUETYPE_FONTTYPE) ? "truetype" : "",
@@ -2453,7 +2453,7 @@ static LRESULT WINAPI window_proc( HWND hwnd, UINT msg, WPARAM wparam, LPARAM lp
break;
case IDS_SCROLL:
case IDS_SEARCH:
- FIXME( "Unhandled yet command: %lx\n", wparam );
+ FIXME( "Unhandled yet command: %Ix\n", wparam );
break;
default:
return DefWindowProcW( hwnd, msg, wparam, lparam );
Jan. 28, 2022
[PATCH 05/15] programs/cmd: enable compilation with long types
by Eric Pouech
---
programs/cmd/Makefile.in | 1 -
programs/cmd/builtins.c | 20 ++++++++++----------
programs/cmd/directory.c | 4 ++--
programs/cmd/wcmdmain.c | 14 +++++++-------
4 files changed, 19 insertions(+), 20 deletions(-)
diff --git a/programs/cmd/Makefile.in b/programs/cmd/Makefile.in
index 8c8489af727..b3b33aa1413 100644
--- a/programs/cmd/Makefile.in
+++ b/programs/cmd/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = cmd.exe
IMPORTS = shell32 user32 advapi32
diff --git a/programs/cmd/builtins.c b/programs/cmd/builtins.c
index 2fc7e07f7aa..963a9eaf361 100644
--- a/programs/cmd/builtins.c
+++ b/programs/cmd/builtins.c
@@ -344,7 +344,7 @@ void WCMD_choice (const WCHAR * args) {
}
if (opt_timeout)
- WINE_FIXME("timeout not supported: %c,%d\n", opt_default, opt_timeout);
+ WINE_FIXME("timeout not supported: %c,%ld\n", opt_default, opt_timeout);
if (have_console)
SetConsoleMode(GetStdHandle(STD_INPUT_HANDLE), 0);
@@ -396,7 +396,7 @@ void WCMD_choice (const WCHAR * args) {
SetConsoleMode(GetStdHandle(STD_INPUT_HANDLE), oldmode);
errorlevel = (ptr - opt_c) + 1;
- WINE_TRACE("answer: %d\n", errorlevel);
+ WINE_TRACE("answer: %ld\n", errorlevel);
heap_free(my_command);
return;
}
@@ -427,12 +427,12 @@ static BOOL WCMD_AppendEOF(WCHAR *filename)
OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
if (h == INVALID_HANDLE_VALUE) {
- WINE_ERR("Failed to open %s (%d)\n", wine_dbgstr_w(filename), GetLastError());
+ WINE_ERR("Failed to open %s (%ld)\n", wine_dbgstr_w(filename), GetLastError());
return FALSE;
} else {
SetFilePointer (h, 0, NULL, FILE_END);
if (!WriteFile(h, &eof, 1, &bytes_written, NULL)) {
- WINE_ERR("Failed to append EOF to %s (%d)\n", wine_dbgstr_w(filename), GetLastError());
+ WINE_ERR("Failed to append EOF to %s (%ld)\n", wine_dbgstr_w(filename), GetLastError());
CloseHandle(h);
return FALSE;
}
@@ -491,7 +491,7 @@ static BOOL WCMD_ManualCopy(WCHAR *srcname, WCHAR *dstname, BOOL ascii, BOOL app
in = CreateFileW(srcname, GENERIC_READ, 0, NULL,
OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
if (in == INVALID_HANDLE_VALUE) {
- WINE_ERR("Failed to open %s (%d)\n", wine_dbgstr_w(srcname), GetLastError());
+ WINE_ERR("Failed to open %s (%ld)\n", wine_dbgstr_w(srcname), GetLastError());
return FALSE;
}
@@ -499,7 +499,7 @@ static BOOL WCMD_ManualCopy(WCHAR *srcname, WCHAR *dstname, BOOL ascii, BOOL app
out = CreateFileW(dstname, GENERIC_WRITE, 0, NULL,
append?OPEN_EXISTING:CREATE_ALWAYS, FILE_ATTRIBUTE_NORMAL, NULL);
if (out == INVALID_HANDLE_VALUE) {
- WINE_ERR("Failed to open %s (%d)\n", wine_dbgstr_w(dstname), GetLastError());
+ WINE_ERR("Failed to open %s (%ld)\n", wine_dbgstr_w(dstname), GetLastError());
CloseHandle(in);
return FALSE;
}
@@ -526,12 +526,12 @@ static BOOL WCMD_ManualCopy(WCHAR *srcname, WCHAR *dstname, BOOL ascii, BOOL app
if (bytesread) {
ok = WriteFile(out, buffer, bytesread, &byteswritten, NULL);
if (!ok || byteswritten != bytesread) {
- WINE_ERR("Unexpected failure writing to %s, rc=%d\n",
+ WINE_ERR("Unexpected failure writing to %s, rc=%ld\n",
wine_dbgstr_w(dstname), GetLastError());
}
}
} else {
- WINE_ERR("Unexpected failure reading from %s, rc=%d\n",
+ WINE_ERR("Unexpected failure reading from %s, rc=%ld\n",
wine_dbgstr_w(srcname), GetLastError());
}
} while (ok && bytesread > 0);
@@ -2442,7 +2442,7 @@ void WCMD_for (WCHAR *p, CMD_LIST **cmdList) {
if (useNumbers) {
WCHAR thisNum[20];
- WINE_TRACE("FOR /L provided range from %d to %d step %d\n",
+ WINE_TRACE("FOR /L provided range from %ld to %ld step %ld\n",
numbers[0], numbers[2], numbers[1]);
for (i=numbers[0];
(numbers[1]<0)? i>=numbers[2] : i<=numbers[2];
@@ -4775,7 +4775,7 @@ void WCMD_assoc (const WCHAR *args, BOOL assoc) {
/* Open a key to HKEY_CLASSES_ROOT for enumerating */
if (RegOpenKeyExW(HKEY_CLASSES_ROOT, L"", 0, accessOptions, &key) != ERROR_SUCCESS) {
- WINE_FIXME("Unexpected failure opening HKCR key: %d\n", GetLastError());
+ WINE_FIXME("Unexpected failure opening HKCR key: %ld\n", GetLastError());
return;
}
diff --git a/programs/cmd/directory.c b/programs/cmd/directory.c
index 807f7b386b1..8417687939a 100644
--- a/programs/cmd/directory.c
+++ b/programs/cmd/directory.c
@@ -536,7 +536,7 @@ static void WCMD_dir_trailer(WCHAR drive) {
driveName[0] = drive;
status = GetDiskFreeSpaceExW(driveName, &avail, &total, &freebytes);
- WINE_TRACE("Writing trailer for '%s' gave %d(%d)\n", wine_dbgstr_w(driveName),
+ WINE_TRACE("Writing trailer for '%s' gave %ld(%ld)\n", wine_dbgstr_w(driveName),
status, GetLastError());
if (errorlevel==0 && !bare) {
@@ -727,7 +727,7 @@ void WCMD_directory (WCHAR *args)
p++;
}
p = p - 1; /* So when step on, move to '/' */
- WINE_TRACE("Result: showattrs %x, bits %x\n", showattrs, attrsbits);
+ WINE_TRACE("Result: showattrs %lx, bits %lx\n", showattrs, attrsbits);
break;
default:
SetLastError(ERROR_INVALID_PARAMETER);
diff --git a/programs/cmd/wcmdmain.c b/programs/cmd/wcmdmain.c
index 65601348b05..af54b209d83 100644
--- a/programs/cmd/wcmdmain.c
+++ b/programs/cmd/wcmdmain.c
@@ -132,7 +132,7 @@ void WINAPIV WCMD_output (const WCHAR *format, ...) {
format, 0, 0, (LPWSTR)&string, 0, &ap);
va_end(ap);
if (len == 0 && GetLastError() != ERROR_NO_WORK_DONE)
- WINE_FIXME("Could not format string: le=%u, fmt=%s\n", GetLastError(), wine_dbgstr_w(format));
+ WINE_FIXME("Could not format string: le=%lu, fmt=%s\n", GetLastError(), wine_dbgstr_w(format));
else
{
WCMD_output_asis_len(string, len, GetStdHandle(STD_OUTPUT_HANDLE));
@@ -157,7 +157,7 @@ void WINAPIV WCMD_output_stderr (const WCHAR *format, ...) {
format, 0, 0, (LPWSTR)&string, 0, &ap);
va_end(ap);
if (len == 0 && GetLastError() != ERROR_NO_WORK_DONE)
- WINE_FIXME("Could not format string: le=%u, fmt=%s\n", GetLastError(), wine_dbgstr_w(format));
+ WINE_FIXME("Could not format string: le=%lu, fmt=%s\n", GetLastError(), wine_dbgstr_w(format));
else
{
WCMD_output_asis_len(string, len, GetStdHandle(STD_ERROR_HANDLE));
@@ -181,7 +181,7 @@ WCHAR* WINAPIV WCMD_format_string (const WCHAR *format, ...)
format, 0, 0, (LPWSTR)&string, 0, &ap);
va_end(ap);
if (len == 0 && GetLastError() != ERROR_NO_WORK_DONE) {
- WINE_FIXME("Could not format string: le=%u, fmt=%s\n", GetLastError(), wine_dbgstr_w(format));
+ WINE_FIXME("Could not format string: le=%lu, fmt=%s\n", GetLastError(), wine_dbgstr_w(format));
string = (WCHAR*)LocalAlloc(LMEM_FIXED, 2);
*string = 0;
}
@@ -303,7 +303,7 @@ void WCMD_print_error (void) {
status = FormatMessageW(FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM,
NULL, error_code, 0, (LPWSTR) &lpMsgBuf, 0, NULL);
if (!status) {
- WINE_FIXME ("Cannot display message for error %d, status %d\n",
+ WINE_FIXME ("Cannot display message for error %ld, status %ld\n",
error_code, GetLastError());
return;
}
@@ -1462,7 +1462,7 @@ void WCMD_execute (const WCHAR *command, const WCHAR *redirects,
GetCurrentProcess(),
&h,
0, TRUE, DUPLICATE_SAME_ACCESS) == 0) {
- WINE_FIXME("Duplicating handle failed with gle %d\n", GetLastError());
+ WINE_FIXME("Duplicating handle failed with gle %ld\n", GetLastError());
}
WINE_TRACE("Redirect %d (%p) to %d (%p)\n", handle, GetStdHandle(idx_stdhandles[idx]), idx, h);
@@ -1664,7 +1664,7 @@ WCHAR *WCMD_LoadMessage(UINT id) {
static WCHAR msg[2048];
if (!LoadStringW(GetModuleHandleW(NULL), id, msg, ARRAY_SIZE(msg))) {
- WINE_FIXME("LoadString failed with %d\n", GetLastError());
+ WINE_FIXME("LoadString failed with %ld\n", GetLastError());
lstrcpyW(msg, L"Failed!");
}
return msg;
@@ -2442,7 +2442,7 @@ int __cdecl wmain (int argc, WCHAR *argvW[])
/* Pre initialize some messages */
lstrcpyW(anykey, WCMD_LoadMessage(WCMD_ANYKEY));
- sprintf(osver, "%d.%d.%d", osv.dwMajorVersion, osv.dwMinorVersion, osv.dwBuildNumber);
+ sprintf(osver, "%ld.%ld.%ld", osv.dwMajorVersion, osv.dwMinorVersion, osv.dwBuildNumber);
cmd = WCMD_format_string(WCMD_LoadMessage(WCMD_VERSION), osver);
lstrcpyW(version_string, cmd);
LocalFree(cmd);
Jan. 28, 2022
[PATCH 04/15] programs/chcp.com: enable compilation with long types
by Eric Pouech
---
programs/chcp.com/Makefile.in | 1 -
programs/chcp.com/main.c | 4 ++--
2 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/programs/chcp.com/Makefile.in b/programs/chcp.com/Makefile.in
index 7a55d3cf15f..c7037abb10f 100644
--- a/programs/chcp.com/Makefile.in
+++ b/programs/chcp.com/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = chcp.com
IMPORTS = kernelbase
diff --git a/programs/chcp.com/main.c b/programs/chcp.com/main.c
index 31ddba4c137..6c5864d0e19 100644
--- a/programs/chcp.com/main.c
+++ b/programs/chcp.com/main.c
@@ -56,7 +56,7 @@ static void output_formatstring(const WCHAR *fmt, va_list va_args)
fmt, 0, 0, (WCHAR *)&str, 0, &va_args);
if (!len && GetLastError() != ERROR_NO_WORK_DONE)
{
- WINE_FIXME("Could not format string: le=%u, fmt=%s\n", GetLastError(), wine_dbgstr_w(fmt));
+ WINE_FIXME("Could not format string: le=%lu, fmt=%s\n", GetLastError(), wine_dbgstr_w(fmt));
return;
}
output_writeconsole(str, len);
@@ -71,7 +71,7 @@ static void WINAPIV output_message(unsigned int id, ...)
if (!(len = LoadStringW(GetModuleHandleW(NULL), id, (WCHAR *)&fmt, 0)))
{
- WINE_FIXME("LoadString failed with %d\n", GetLastError());
+ WINE_FIXME("LoadString failed with %ld\n", GetLastError());
return;
}
Jan. 28, 2022
[PATCH 03/15] programs/cabarc: enable compilation with long types
by Eric Pouech
---
programs/cabarc/Makefile.in | 1 -
programs/cabarc/cabarc.c | 2 +-
2 files changed, 1 insertion(+), 2 deletions(-)
diff --git a/programs/cabarc/Makefile.in b/programs/cabarc/Makefile.in
index c0c825500de..769df20457d 100644
--- a/programs/cabarc/Makefile.in
+++ b/programs/cabarc/Makefile.in
@@ -1,4 +1,3 @@
-EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = cabarc.exe
IMPORTS = cabinet
diff --git a/programs/cabarc/cabarc.c b/programs/cabarc/cabarc.c
index 3eb28fe9083..c4622e43046 100644
--- a/programs/cabarc/cabarc.c
+++ b/programs/cabarc/cabarc.c
@@ -299,7 +299,7 @@ static void create_directories( const WCHAR *name )
{
*p = 0;
if (!CreateDirectoryW( path, NULL ))
- WINE_TRACE("Couldn't create directory %s - error: %d\n", wine_dbgstr_w(path), GetLastError());
+ WINE_TRACE("Couldn't create directory %s - error: %ld\n", wine_dbgstr_w(path), GetLastError());
*p = '\\';
p = wcschr(p+1, '\\');
}
Jan. 28, 2022