From: Eric Pouech <epouech(a)codeweavers.com> Also resolving a SAST report. Signed-off-by: Eric Pouech <epouech(a)codeweavers.com> --- programs/cmd/batch.c | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/programs/cmd/batch.c b/programs/cmd/batch.c index 591b3bcd489..035f8accc00 100644 --- a/programs/cmd/batch.c +++ b/programs/cmd/batch.c @@ -536,14 +536,11 @@ void WCMD_HandleTildeModifiers(WCHAR **start, BOOL atExecute) /* 4. Handle 'z' : File length (File doesn't have to exist) */ if (wmemchr(firstModifier, 'z', modifierLen) != NULL) { - /* FIXME: Output full 64 bit size (sprintf does not support I64 here) */ - ULONG/*64*/ fullsize = /*(fileInfo.nFileSizeHigh << 32) +*/ - fileInfo.nFileSizeLow; - doneModifier = TRUE; if (exists) { + ULONG64 fullsize = ((ULONG64)fileInfo.nFileSizeHigh << 32) | fileInfo.nFileSizeLow; if (finaloutput[0] != 0x00) lstrcatW(finaloutput, L" "); - wsprintfW(thisoutput, L"%u", fullsize); + wsprintfW(thisoutput, L"%I64u", fullsize); lstrcatW(finaloutput, thisoutput); } } -- GitLab https://gitlab.winehq.org/wine/wine/-/merge_requests/9273