Alexandre Julliard : Make some variables static.

Alexandre Julliard julliard at winehq.org
Tue Nov 6 08:24:45 CST 2007


Module: wine
Branch: master
Commit: 0590fe2ecf25705d09a308da58b0b1338be0f166
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=0590fe2ecf25705d09a308da58b0b1338be0f166

Author: Alexandre Julliard <julliard at winehq.org>
Date:   Tue Nov  6 14:38:54 2007 +0100

Make some variables static.

---

 dlls/advapi32/security.c  |    2 +-
 dlls/credui/credui_main.c |    2 +-
 dlls/msi/msi_main.c       |    5 +++--
 dlls/rsaenh/mpi.c         |    5 ++++-
 dlls/rsaenh/tomcrypt.h    |    3 ---
 5 files changed, 9 insertions(+), 8 deletions(-)

diff --git a/dlls/advapi32/security.c b/dlls/advapi32/security.c
index 1c55d0a..bd2ac06 100644
--- a/dlls/advapi32/security.c
+++ b/dlls/advapi32/security.c
@@ -137,7 +137,7 @@ typedef struct WELLKOWNRID
     DWORD Rid;
 } WELLKNOWNRID;
 
-WELLKNOWNRID WellKnownRids[] = {
+static const WELLKNOWNRID WellKnownRids[] = {
     { WinAccountAdministratorSid,    DOMAIN_USER_RID_ADMIN },
     { WinAccountGuestSid,            DOMAIN_USER_RID_GUEST },
     { WinAccountKrbtgtSid,           DOMAIN_USER_RID_KRBTGT },
diff --git a/dlls/credui/credui_main.c b/dlls/credui/credui_main.c
index 93d5b88..f9e24eb 100644
--- a/dlls/credui/credui_main.c
+++ b/dlls/credui/credui_main.c
@@ -45,7 +45,7 @@ struct pending_credentials
 
 static HINSTANCE hinstCredUI;
 
-struct list pending_credentials_list = LIST_INIT(pending_credentials_list);
+static struct list pending_credentials_list = LIST_INIT(pending_credentials_list);
 
 static CRITICAL_SECTION csPendingCredentials;
 static CRITICAL_SECTION_DEBUG critsect_debug =
diff --git a/dlls/msi/msi_main.c b/dlls/msi/msi_main.c
index cf3f30c..2c32b3b 100644
--- a/dlls/msi/msi_main.c
+++ b/dlls/msi/msi_main.c
@@ -44,10 +44,11 @@ INSTALLUI_HANDLERW gUIHandlerW = NULL;
 DWORD gUIFilter = 0;
 LPVOID gUIContext = NULL;
 WCHAR gszLogFile[MAX_PATH];
-WCHAR msi_path[MAX_PATH];
-ITypeLib *msi_typelib = NULL;
 HINSTANCE msi_hInstance;
 
+static WCHAR msi_path[MAX_PATH];
+static ITypeLib *msi_typelib;
+
 /*
  * Dll lifetime tracking declaration
  */
diff --git a/dlls/rsaenh/mpi.c b/dlls/rsaenh/mpi.c
index a7408a4..c6f083b 100644
--- a/dlls/rsaenh/mpi.c
+++ b/dlls/rsaenh/mpi.c
@@ -31,6 +31,9 @@
 #include <stdarg.h>
 #include "tomcrypt.h"
 
+/* table of first PRIME_SIZE primes */
+static const mp_digit __prime_tab[];
+
 /* Known optimal configurations
  CPU                    /Compiler     /MUL CUTOFF/SQR CUTOFF
 -------------------------------------------------------------
@@ -3808,7 +3811,7 @@ mp_zero (mp_int * a)
   memset (a->dp, 0, sizeof (mp_digit) * a->alloc);
 }
 
-const mp_digit __prime_tab[] = {
+static const mp_digit __prime_tab[] = {
   0x0002, 0x0003, 0x0005, 0x0007, 0x000B, 0x000D, 0x0011, 0x0013,
   0x0017, 0x001D, 0x001F, 0x0025, 0x0029, 0x002B, 0x002F, 0x0035,
   0x003B, 0x003D, 0x0043, 0x0047, 0x0049, 0x004F, 0x0053, 0x0059,
diff --git a/dlls/rsaenh/tomcrypt.h b/dlls/rsaenh/tomcrypt.h
index b9e29d9..53c2f40 100644
--- a/dlls/rsaenh/tomcrypt.h
+++ b/dlls/rsaenh/tomcrypt.h
@@ -473,9 +473,6 @@ int mp_exptmod(const mp_int *a, const mp_int *b, mp_int *c, mp_int *d);
 /* number of primes */
 #define PRIME_SIZE      256
 
-/* table of first PRIME_SIZE primes */
-extern const mp_digit __prime_tab[];
-
 /* result=1 if a is divisible by one of the first PRIME_SIZE primes */
 int mp_prime_is_divisible(const mp_int *a, int *result);
 




More information about the wine-cvs mailing list