summaryrefslogtreecommitdiffstats
path: root/win
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2012-04-23 13:17:12 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2012-04-23 13:17:12 (GMT)
commitab4c7318fd564b0196bd38b6573eb84c9d51e2d1 (patch)
tree3326a12bac5c8ff056623f23c433b10d6d915585 /win
parent75d9b50fe87d98b7e6ef6058d0e39cd0c46e8c66 (diff)
parent6f14ff020a548ab6adcb30836c498ab0fe921970 (diff)
downloadtcl-ab4c7318fd564b0196bd38b6573eb84c9d51e2d1.zip
tcl-ab4c7318fd564b0196bd38b6573eb84c9d51e2d1.tar.gz
tcl-ab4c7318fd564b0196bd38b6573eb84c9d51e2d1.tar.bz2
make some more internal tables const
Diffstat (limited to 'win')
-rw-r--r--win/tclWinFCmd.c2
-rw-r--r--win/tclWinPipe.c2
-rw-r--r--win/tclWinReg.c2
-rw-r--r--win/tclWinTest.c2
-rw-r--r--win/tclWinTime.c6
5 files changed, 7 insertions, 7 deletions
diff --git a/win/tclWinFCmd.c b/win/tclWinFCmd.c
index a1338a7..d918b4a 100644
--- a/win/tclWinFCmd.c
+++ b/win/tclWinFCmd.c
@@ -50,7 +50,7 @@ enum {
WIN_SYSTEM_ATTRIBUTE
};
-static int attributeArray[] = {FILE_ATTRIBUTE_ARCHIVE, FILE_ATTRIBUTE_HIDDEN,
+static const int attributeArray[] = {FILE_ATTRIBUTE_ARCHIVE, FILE_ATTRIBUTE_HIDDEN,
0, FILE_ATTRIBUTE_READONLY, 0, FILE_ATTRIBUTE_SYSTEM};
diff --git a/win/tclWinPipe.c b/win/tclWinPipe.c
index b29dde4..842228a 100644
--- a/win/tclWinPipe.c
+++ b/win/tclWinPipe.c
@@ -1369,7 +1369,7 @@ ApplicationType(
Tcl_DString nameBuf, ds;
const TCHAR *nativeName;
WCHAR nativeFullPath[MAX_PATH];
- static char extensions[][5] = {"", ".com", ".exe", ".bat"};
+ static const char extensions[][5] = {"", ".com", ".exe", ".bat"};
/*
* Look for the program as an external program. First try the name as it
diff --git a/win/tclWinReg.c b/win/tclWinReg.c
index 8eaf2a7..f2ac367 100644
--- a/win/tclWinReg.c
+++ b/win/tclWinReg.c
@@ -52,7 +52,7 @@ static CONST char *rootKeyNames[] = {
"HKEY_PERFORMANCE_DATA", "HKEY_DYN_DATA", NULL
};
-static HKEY rootKeys[] = {
+static const HKEY rootKeys[] = {
HKEY_LOCAL_MACHINE, HKEY_USERS, HKEY_CLASSES_ROOT, HKEY_CURRENT_USER,
HKEY_CURRENT_CONFIG, HKEY_PERFORMANCE_DATA, HKEY_DYN_DATA
};
diff --git a/win/tclWinTest.c b/win/tclWinTest.c
index d0bbb09..34aea42 100644
--- a/win/tclWinTest.c
+++ b/win/tclWinTest.c
@@ -428,7 +428,7 @@ TestExceptionCmd(
"invalid_disp", "guard_page", "invalid_handle", "ctrl+c",
NULL
};
- static DWORD exceptions[] = {
+ static const DWORD exceptions[] = {
EXCEPTION_ACCESS_VIOLATION, EXCEPTION_DATATYPE_MISALIGNMENT,
EXCEPTION_ARRAY_BOUNDS_EXCEEDED, EXCEPTION_FLT_DENORMAL_OPERAND,
EXCEPTION_FLT_DIVIDE_BY_ZERO, EXCEPTION_FLT_INEXACT_RESULT,
diff --git a/win/tclWinTime.c b/win/tclWinTime.c
index 3ae108b..f34884a 100644
--- a/win/tclWinTime.c
+++ b/win/tclWinTime.c
@@ -27,11 +27,11 @@
* month, where index 1 is January.
*/
-static int normalDays[] = {
+static const int normalDays[] = {
-1, 30, 58, 89, 119, 150, 180, 211, 242, 272, 303, 333, 364
};
-static int leapDays[] = {
+static const int leapDays[] = {
-1, 30, 59, 90, 120, 151, 181, 212, 243, 273, 304, 334, 365
};
@@ -734,7 +734,7 @@ ComputeGMT(
struct tm *tmPtr;
long tmp, rem;
int isLeap;
- int *days;
+ const int *days;
ThreadSpecificData *tsdPtr = TCL_TSD_INIT(&dataKey);
tmPtr = &tsdPtr->tm;