[MSI] Apply Wine commit fdac39f by Hans Leidekker: Pass correct length to GetDateFormatW. CORE-13902

This commit is contained in:
Amine Khaldi 2017-10-20 18:40:15 +01:00
parent b539380dac
commit fec16ab0c0

View file

@ -2289,7 +2289,7 @@ static MSIRECORD *msi_get_property_row( MSIDATABASE *db, LPCWSTR name )
if (!length)
return NULL;
buffer = msi_alloc(length * sizeof(WCHAR));
GetDateFormatW(LOCALE_USER_DEFAULT, DATE_SHORTDATE, NULL, NULL, buffer, sizeof(WCHAR));
GetDateFormatW(LOCALE_USER_DEFAULT, DATE_SHORTDATE, NULL, NULL, buffer, length);
row = MSI_CreateRecord(1);
if (!row)
@ -2304,7 +2304,7 @@ static MSIRECORD *msi_get_property_row( MSIDATABASE *db, LPCWSTR name )
if (!length)
return NULL;
buffer = msi_alloc(length * sizeof(WCHAR));
GetTimeFormatW(LOCALE_USER_DEFAULT, TIME_NOTIMEMARKER, NULL, NULL, buffer, sizeof(WCHAR));
GetTimeFormatW(LOCALE_USER_DEFAULT, TIME_NOTIMEMARKER, NULL, NULL, buffer, length);
row = MSI_CreateRecord(1);
if (!row)