[SMSS] Fix some x64 warnings C4267 "conversion from 'size_t' to 'ULONG', possible loss of data"

This commit is contained in:
Hermès Bélusca-Maïto 2022-11-06 16:47:09 +01:00
parent f0dd1e7b57
commit c48ca5b022
No known key found for this signature in database
GPG key ID: 3B2539C65E7B93D0

View file

@ -1745,7 +1745,7 @@ SmpCreateDynamicEnvironmentVariables(VOID)
0,
REG_SZ,
ValueData,
(wcslen(ValueData) + 1) * sizeof(WCHAR));
(ULONG)(wcslen(ValueData) + 1) * sizeof(WCHAR));
if (!NT_SUCCESS(Status))
{
DPRINT1("SMSS: Failed writing %wZ environment variable - %x\n",
@ -1783,7 +1783,7 @@ SmpCreateDynamicEnvironmentVariables(VOID)
0,
REG_SZ,
ValueData,
(wcslen(ValueData) + 1) * sizeof(WCHAR));
(ULONG)(wcslen(ValueData) + 1) * sizeof(WCHAR));
if (!NT_SUCCESS(Status))
{
DPRINT1("SMSS: Failed writing %wZ environment variable - %x\n",
@ -1801,7 +1801,7 @@ SmpCreateDynamicEnvironmentVariables(VOID)
0,
REG_SZ,
ValueBuffer,
(wcslen(ValueBuffer) + 1) * sizeof(WCHAR));
(ULONG)(wcslen(ValueBuffer) + 1) * sizeof(WCHAR));
if (!NT_SUCCESS(Status))
{
DPRINT1("SMSS: Failed writing %wZ environment variable - %x\n",
@ -1927,7 +1927,7 @@ SmpCreateDynamicEnvironmentVariables(VOID)
0,
REG_SZ,
ValueBuffer,
(wcslen(ValueBuffer) + 1) * sizeof(WCHAR));
(ULONG)(wcslen(ValueBuffer) + 1) * sizeof(WCHAR));
if (!NT_SUCCESS(Status))
{
DPRINT1("SMSS: Failed writing %wZ environment variable - %x\n",
@ -1945,7 +1945,7 @@ SmpCreateDynamicEnvironmentVariables(VOID)
0,
REG_SZ,
ValueBuffer,
(wcslen(ValueBuffer) + 1) * sizeof(WCHAR));
(ULONG)(wcslen(ValueBuffer) + 1) * sizeof(WCHAR));
if (!NT_SUCCESS(Status))
{
DPRINT1("SMSS: Failed writing %wZ environment variable - %x\n",
@ -2001,7 +2001,7 @@ SmpCreateDynamicEnvironmentVariables(VOID)
0,
REG_SZ,
ValueBuffer,
(wcslen(ValueBuffer) + 1) * sizeof(WCHAR));
(ULONG)(wcslen(ValueBuffer) + 1) * sizeof(WCHAR));
if (!NT_SUCCESS(Status))
{
DPRINT1("SMSS: Failed writing %wZ environment variable - %x\n",