Used proper format string for wide print size_t
This commit is contained in:
parent
d73d0d4610
commit
b0c4bb5e86
@ -36,6 +36,8 @@
|
|||||||
|
|
||||||
#include <freerdp/client/printer.h>
|
#include <freerdp/client/printer.h>
|
||||||
|
|
||||||
|
#define WIDEN_INT(x) L##x
|
||||||
|
#define WIDEN(x) WIDEN_INT(x)
|
||||||
#define PRINTER_TAG CHANNELS_TAG("printer.client")
|
#define PRINTER_TAG CHANNELS_TAG("printer.client")
|
||||||
#ifdef WITH_DEBUG_WINPR
|
#ifdef WITH_DEBUG_WINPR
|
||||||
#define DEBUG_WINPR(...) WLog_DBG(PRINTER_TAG, __VA_ARGS__)
|
#define DEBUG_WINPR(...) WLog_DBG(PRINTER_TAG, __VA_ARGS__)
|
||||||
@ -91,9 +93,10 @@ static WCHAR* printer_win_get_printjob_name(size_t id)
|
|||||||
if (!str)
|
if (!str)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
rc = swprintf_s(str, len, L"FreeRDP Print %04d-%02d-%02d% 02d-%02d-%02d - Job %lu\0",
|
rc = swprintf_s(
|
||||||
t->tm_year + 1900, t->tm_mon + 1, t->tm_mday, t->tm_hour, t->tm_min, t->tm_sec,
|
str, len,
|
||||||
id);
|
WIDEN("FreeRDP Print %04d-%02d-%02d% 02d-%02d-%02d - Job %") WIDEN(PRIuz) WIDEN("\0"),
|
||||||
|
t->tm_year + 1900, t->tm_mon + 1, t->tm_mday, t->tm_hour, t->tm_min, t->tm_sec, id);
|
||||||
|
|
||||||
return str;
|
return str;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user