Frédéric Delanoy : comctl32: Avoid hardcoding array lengths.
Module: wine Branch: master Commit: 954e6eba7e2c4df401e3c1de4bb23216314c349c URL: http://source.winehq.org/git/wine.git/?a=commit;h=954e6eba7e2c4df401e3c1de4b... Author: Frédéric Delanoy <frederic.delanoy(a)gmail.com> Date: Mon Nov 21 19:19:46 2011 +0100 comctl32: Avoid hardcoding array lengths. --- dlls/comctl32/ipaddress.c | 2 +- dlls/comdlg32/printdlg.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/dlls/comctl32/ipaddress.c b/dlls/comctl32/ipaddress.c index e51ae08..97b6a0f 100644 --- a/dlls/comctl32/ipaddress.c +++ b/dlls/comctl32/ipaddress.c @@ -339,7 +339,7 @@ static BOOL IPADDRESS_SetRange (IPADDRESS_INFO *infoPtr, int index, WORD range) static void IPADDRESS_ClearAddress (const IPADDRESS_INFO *infoPtr) { - WCHAR nil[1] = { 0 }; + static const WCHAR nil[] = { 0 }; int i; TRACE("\n"); diff --git a/dlls/comdlg32/printdlg.c b/dlls/comdlg32/printdlg.c index ee4dab2..aea5224 100644 --- a/dlls/comdlg32/printdlg.c +++ b/dlls/comdlg32/printdlg.c @@ -2433,7 +2433,7 @@ static WCHAR get_decimal_sep(void) if(!sep) { - WCHAR buf[2] = {'.',0}; + WCHAR buf[] = {'.', 0}; GetLocaleInfoW(LOCALE_USER_DEFAULT, LOCALE_SDECIMAL, buf, sizeof(buf) / sizeof(buf[0])); sep = buf[0]; }
participants (1)
-
Alexandre Julliard