Alex Henrie : msi: Turn several variables and constants into static constants.
Alexandre Julliard
julliard at winehq.org
Fri Nov 30 14:34:41 CST 2018
Module: wine
Branch: master
Commit: 6a833ce0b39ae9f57162f6ffd3ff55f19f3ba540
URL: https://source.winehq.org/git/wine.git/?a=commit;h=6a833ce0b39ae9f57162f6ffd3ff55f19f3ba540
Author: Alex Henrie <alexhenrie24 at gmail.com>
Date: Fri Nov 30 00:14:12 2018 -0700
msi: Turn several variables and constants into static constants.
Signed-off-by: Alex Henrie <alexhenrie24 at gmail.com>
Signed-off-by: Hans Leidekker <hans at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/msi/action.c | 4 ++--
dlls/msi/database.c | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/dlls/msi/action.c b/dlls/msi/action.c
index 8ae9dce..9407d36 100644
--- a/dlls/msi/action.c
+++ b/dlls/msi/action.c
@@ -160,7 +160,7 @@ static const WCHAR szINSTALL[] =
static INT ui_actionstart(MSIPACKAGE *package, LPCWSTR action, LPCWSTR description, LPCWSTR template)
{
- WCHAR query[] = {'S','E','L','E','C','T',' ','*',' ','F','R','O','M',' ',
+ static const WCHAR query[] = {'S','E','L','E','C','T',' ','*',' ','F','R','O','M',' ',
'`','A','c','t','i','o','n','T','e','x','t','`',' ','W','H','E','R','E',' ',
'`','A','c','t','i','o','n','`',' ','=',' ','\'','%','s','\'',0};
MSIRECORD *row, *textrow;
@@ -3546,7 +3546,7 @@ static WCHAR *build_full_keypath( MSIPACKAGE *package, MSICOMPONENT *comp )
{
if (comp->assembly)
{
- const WCHAR prefixW[] = {'<','\\',0};
+ static const WCHAR prefixW[] = {'<','\\',0};
DWORD len = strlenW( prefixW ) + strlenW( comp->assembly->display_name );
WCHAR *keypath = msi_alloc( (len + 1) * sizeof(WCHAR) );
diff --git a/dlls/msi/database.c b/dlls/msi/database.c
index c1fb37b..b8ec393 100644
--- a/dlls/msi/database.c
+++ b/dlls/msi/database.c
@@ -1333,7 +1333,7 @@ static LPWSTR get_key_value(MSIQUERY *view, LPCWSTR key, MSIRECORD *rec)
if (MSI_RecordGetString(rec, i)) /* check record field is a string */
{
/* quote string record fields */
- const WCHAR szQuote[] = {'\'', 0};
+ static const WCHAR szQuote[] = {'\'', 0};
sz += 2;
val = msi_alloc(sz*sizeof(WCHAR));
if (!val)
More information about the wine-cvs
mailing list