msi: Pass correct length to GetDateFormatW.
Hans Leidekker
hans at codeweavers.com
Tue Sep 19 12:37:48 CDT 2017
Signed-off-by: Hans Leidekker <hans at codeweavers.com>
---
dlls/msi/package.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/dlls/msi/package.c b/dlls/msi/package.c
index 7c6ca84..2caec50 100644
--- a/dlls/msi/package.c
+++ b/dlls/msi/package.c
@@ -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)
--
2.1.4
More information about the wine-patches
mailing list