Piotr Caban : msvcrt: Print 0x prefix with %#x format in traces.
Alexandre Julliard
julliard at winehq.org
Tue Feb 8 16:11:46 CST 2022
Module: wine
Branch: master
Commit: 4397d97d91d4480c995a81364f71d7f088a79510
URL: https://source.winehq.org/git/wine.git/?a=commit;h=4397d97d91d4480c995a81364f71d7f088a79510
Author: Piotr Caban <piotr at codeweavers.com>
Date: Tue Feb 8 19:39:12 2022 +0100
msvcrt: Print 0x prefix with %#x format in traces.
Signed-off-by: Piotr Caban <piotr at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/msvcrt/data.c | 2 +-
dlls/msvcrt/file.c | 12 ++++++------
2 files changed, 7 insertions(+), 7 deletions(-)
diff --git a/dlls/msvcrt/data.c b/dlls/msvcrt/data.c
index 8b6c34abf56..d1f514fd460 100644
--- a/dlls/msvcrt/data.c
+++ b/dlls/msvcrt/data.c
@@ -656,7 +656,7 @@ int CDECL _initterm_e(_INITTERM_E_FN *table, _INITTERM_E_FN *end)
TRACE("calling %p\n", **table);
res = (**table)();
if (res)
- TRACE("function %p failed: 0x%x\n", *table, res);
+ TRACE("function %p failed: %#x\n", *table, res);
}
table++;
diff --git a/dlls/msvcrt/file.c b/dlls/msvcrt/file.c
index 7c39a50a656..86c67868381 100644
--- a/dlls/msvcrt/file.c
+++ b/dlls/msvcrt/file.c
@@ -1368,7 +1368,7 @@ int CDECL _locking(int fd, int mode, __msvcrt_long nbytes)
return -1;
}
- TRACE(":fd (%d) by 0x%lx mode %s\n",
+ TRACE(":fd (%d) by %#lx mode %s\n",
fd, nbytes, (mode == _LK_UNLCK) ? "_LK_UNLCK" :
(mode == _LK_LOCK) ? "_LK_LOCK" :
(mode == _LK_NBLCK) ? "_LK_NBLCK" :
@@ -1815,7 +1815,7 @@ int CDECL _fstat64(int fd, struct _stat64* buf)
RtlTimeToSecondsSince1970((LARGE_INTEGER *)&basic_info.LastWriteTime, &dw);
buf->st_mtime = buf->st_ctime = dw;
buf->st_nlink = std_info.NumberOfLinks;
- TRACE(":dwFileAttributes = 0x%lx, mode set to 0x%x\n",
+ TRACE(":dwFileAttributes = %#lx, mode set to %#x\n",
basic_info.FileAttributes, buf->st_mode);
}
release_ioinfo(info);
@@ -2121,7 +2121,7 @@ static unsigned split_oflags(unsigned oflags)
if ((unsupp = oflags & ~(_O_BINARY | _O_TEXT | _O_APPEND | _O_TRUNC | _O_EXCL | _O_CREAT |
_O_RDWR | _O_WRONLY | _O_TEMPORARY | _O_NOINHERIT | _O_SEQUENTIAL |
_O_RANDOM | _O_SHORT_LIVED | _O_WTEXT | _O_U16TEXT | _O_U8TEXT)))
- ERR(":unsupported oflags 0x%04x\n",unsupp);
+ ERR(":unsupported oflags %#x\n",unsupp);
return wxflags;
}
@@ -2212,7 +2212,7 @@ int CDECL _wsopen_dispatch( const wchar_t* path, int oflags, int shflags, int pm
int wxflag;
HANDLE hand;
- TRACE("path: (%s) oflags: 0x%04x shflags: 0x%04x pmode: 0x%04x fd*: %p secure: %d\n",
+ TRACE("path: (%s) oflags: %#x shflags: %#x pmode: %#x fd*: %p secure: %d\n",
debugstr_w(path), oflags, shflags, pmode, fd, secure);
if (!MSVCRT_CHECK_PMT( fd != NULL )) return EINVAL;
@@ -2261,7 +2261,7 @@ int CDECL _wsopen_dispatch( const wchar_t* path, int oflags, int shflags, int pm
sharing = FILE_SHARE_READ | FILE_SHARE_WRITE;
break;
default:
- ERR( "Unhandled shflags 0x%x\n", shflags );
+ ERR( "Unhandled shflags %#x\n", shflags );
return EINVAL;
}
@@ -2547,7 +2547,7 @@ int CDECL _open_osfhandle(intptr_t handle, int oflags)
flags |= split_oflags(oflags);
fd = msvcrt_alloc_fd((HANDLE)handle, flags);
- TRACE(":handle (%Iu) fd (%d) flags 0x%08lx\n", handle, fd, flags);
+ TRACE(":handle (%Iu) fd (%d) flags %#lx\n", handle, fd, flags);
return fd;
}
More information about the wine-cvs
mailing list