summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--animations/source/animcore/factreg.cxx2
-rw-r--r--basic/source/comp/exprgen.cxx4
-rw-r--r--basic/source/comp/parser.cxx4
-rw-r--r--basic/source/comp/token.cxx10
-rw-r--r--basic/source/sbx/sbxscan.cxx2
-rw-r--r--sal/qa/osl/file/osl_File.cxx6
-rw-r--r--sax/source/tools/converter.cxx2
-rw-r--r--sfx2/source/doc/iframe.cxx2
-rw-r--r--sfx2/source/doc/plugin.cxx2
-rw-r--r--sfx2/source/sidebar/Deck.cxx2
-rw-r--r--svtools/source/uno/miscservices.cxx2
11 files changed, 19 insertions, 19 deletions
diff --git a/animations/source/animcore/factreg.cxx b/animations/source/animcore/factreg.cxx
index 4f5b07882a5e..d95798109f07 100644
--- a/animations/source/animcore/factreg.cxx
+++ b/animations/source/animcore/factreg.cxx
@@ -40,7 +40,7 @@ using namespace animcore;
0, 0\
}\
-static struct ImplementationEntry g_entries[] =
+static const struct ImplementationEntry g_entries[] =
{
IMPLEMENTATION_ENTRY( PAR ),
IMPLEMENTATION_ENTRY( SEQ ),
diff --git a/basic/source/comp/exprgen.cxx b/basic/source/comp/exprgen.cxx
index 357809757c5a..762e0e38958b 100644
--- a/basic/source/comp/exprgen.cxx
+++ b/basic/source/comp/exprgen.cxx
@@ -28,7 +28,7 @@ typedef struct {
SbiOpcode eOp; // Opcode
} OpTable;
-static OpTable aOpTable [] = {
+static const OpTable aOpTable [] = {
{ EXPON,_EXP },
{ MUL, _MUL },
{ DIV, _DIV },
@@ -156,7 +156,7 @@ void SbiExprNode::Gen( RecursiveMode eRecMode )
{
pRight->Gen();
}
- for( OpTable* p = aOpTable; p->eTok != NIL; p++ )
+ for( const OpTable* p = aOpTable; p->eTok != NIL; p++ )
{
if( p->eTok == eTok )
{
diff --git a/basic/source/comp/parser.cxx b/basic/source/comp/parser.cxx
index bb53d93b4b24..d61f33444a7b 100644
--- a/basic/source/comp/parser.cxx
+++ b/basic/source/comp/parser.cxx
@@ -38,7 +38,7 @@ struct SbiStatement {
#define Y sal_True
#define N sal_False
-static SbiStatement StmntTable [] = {
+static const SbiStatement StmntTable [] = {
{ ATTRIBUTE, &SbiParser::Attribute, Y, Y, }, // ATTRIBUTE
{ CALL, &SbiParser::Call, N, Y, }, // CALL
{ CLOSE, &SbiParser::Close, N, Y, }, // CLOSE
@@ -409,7 +409,7 @@ bool SbiParser::Parse()
// statement parsers
- SbiStatement* p;
+ const SbiStatement* p;
for( p = StmntTable; p->eTok != NIL; p++ )
if( p->eTok == eCurTok )
break;
diff --git a/basic/source/comp/token.cxx b/basic/source/comp/token.cxx
index 0da1c51476d9..f3d27eddbcd1 100644
--- a/basic/source/comp/token.cxx
+++ b/basic/source/comp/token.cxx
@@ -25,9 +25,9 @@ struct TokenTable { SbiToken t; const char *s; };
static short nToken; // number of tokens
-static TokenTable* pTokTable;
+static const TokenTable* pTokTable;
-static TokenTable aTokTable_Basic [] = {
+static const TokenTable aTokTable_Basic [] = {
{ CAT, "&" },
{ MUL, "*" },
{ PLUS, "+" },
@@ -220,7 +220,7 @@ SbiTokenizer::SbiTokenizer( const OUString& rSrc, StarBASIC* pb )
bEos = bKeywords = bErrorIsSymbol = true;
if( !nToken )
{
- TokenTable *tp;
+ const TokenTable *tp;
for( nToken = 0, tp = pTokTable; tp->t; nToken++, tp++ )
{}
}
@@ -297,7 +297,7 @@ const OUString& SbiTokenizer::Symbol( SbiToken t )
default:
break;
}
- TokenTable* tp = pTokTable;
+ const TokenTable* tp = pTokTable;
for( short i = 0; i < nToken; i++, tp++ )
{
if( tp->t == t )
@@ -336,7 +336,7 @@ SbiToken SbiTokenizer::Next()
bEos = IsEoln( eCurTok );
return eCurTok;
}
- TokenTable *tp;
+ const TokenTable *tp;
if( !NextSym() )
{
diff --git a/basic/source/sbx/sbxscan.cxx b/basic/source/sbx/sbxscan.cxx
index 157407ed16d3..180de7ed0ac6 100644
--- a/basic/source/sbx/sbxscan.cxx
+++ b/basic/source/sbx/sbxscan.cxx
@@ -288,7 +288,7 @@ SbxError SbxValue::ScanNumIntnl( const OUString& rSrc, double& nVal, bool bSingl
}
-static double roundArray[] = {
+static const double roundArray[] = {
5.0e+0, 0.5e+0, 0.5e-1, 0.5e-2, 0.5e-3, 0.5e-4, 0.5e-5, 0.5e-6, 0.5e-7,
0.5e-8, 0.5e-9, 0.5e-10,0.5e-11,0.5e-12,0.5e-13,0.5e-14,0.5e-15 };
diff --git a/sal/qa/osl/file/osl_File.cxx b/sal/qa/osl/file/osl_File.cxx
index 15df1b8c8c40..6357a8b028cd 100644
--- a/sal/qa/osl/file/osl_File.cxx
+++ b/sal/qa/osl/file/osl_File.cxx
@@ -6198,9 +6198,9 @@ namespace osl_Directory
#ifdef WNT
//##########################################
- char* get_unused_drive_letter()
+ const char* get_unused_drive_letter()
{
- static char m_aBuff[] = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
+ static const char m_aBuff[] = "ABCDEFGHIJKLMNOPQRSTUVWXYZ";
DWORD ld = GetLogicalDrives();
DWORD i = 4;
@@ -6218,7 +6218,7 @@ namespace osl_Directory
//##########################################
void at_invalid_logical_drive()
{
- char* drv = get_unused_drive_letter();
+ const char* drv = get_unused_drive_letter();
char buff[PATH_BUFFER_SIZE];
memset(buff, 0, sizeof(buff));
diff --git a/sax/source/tools/converter.cxx b/sax/source/tools/converter.cxx
index da3d3f1bd90b..6cfe6880856a 100644
--- a/sax/source/tools/converter.cxx
+++ b/sax/source/tools/converter.cxx
@@ -1331,7 +1331,7 @@ static bool lcl_isLeapYear(const sal_uInt32 nYear)
static sal_uInt16
lcl_MaxDaysPerMonth(const sal_Int32 nMonth, const sal_Int32 nYear)
{
- static sal_uInt16 s_MaxDaysPerMonth[12] =
+ static const sal_uInt16 s_MaxDaysPerMonth[12] =
{ 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 };
OSL_ASSERT(0 < nMonth && nMonth <= 12);
if ((2 == nMonth) && lcl_isLeapYear(nYear))
diff --git a/sfx2/source/doc/iframe.cxx b/sfx2/source/doc/iframe.cxx
index d43d3383e3fe..9f6c15e48740 100644
--- a/sfx2/source/doc/iframe.cxx
+++ b/sfx2/source/doc/iframe.cxx
@@ -77,7 +77,7 @@ IFrameWindow_Impl::IFrameWindow_Impl( Window *pParent, sal_Bool bHasBorder, WinB
const SfxItemPropertyMapEntry* lcl_GetIFramePropertyMap_Impl()
{
- static SfxItemPropertyMapEntry aIFramePropertyMap_Impl[] =
+ static const SfxItemPropertyMapEntry aIFramePropertyMap_Impl[] =
{
{ MAP_CHAR_LEN("FrameIsAutoBorder"), WID_FRAME_IS_AUTO_BORDER, &::getBooleanCppuType(), PROPERTY_UNBOUND, 0 },
{ MAP_CHAR_LEN("FrameIsAutoScroll"), WID_FRAME_IS_AUTO_SCROLL, &::getBooleanCppuType(), PROPERTY_UNBOUND, 0 },
diff --git a/sfx2/source/doc/plugin.cxx b/sfx2/source/doc/plugin.cxx
index 9a59132ccdf9..3d24f23a96b4 100644
--- a/sfx2/source/doc/plugin.cxx
+++ b/sfx2/source/doc/plugin.cxx
@@ -60,7 +60,7 @@ void PluginWindow_Impl::Resize()
#define WID_URL 3
const SfxItemPropertyMapEntry* lcl_GetPluginPropertyMap_Impl()
{
- static SfxItemPropertyMapEntry aPluginPropertyMap_Impl[] =
+ static const SfxItemPropertyMapEntry aPluginPropertyMap_Impl[] =
{
{ MAP_CHAR_LEN("PluginCommands"), WID_COMMANDS, &::getCppuType((::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue >*)0), PROPERTY_UNBOUND, 0},
{ MAP_CHAR_LEN("PluginMimeType"), WID_MIMETYPE, &::getCppuType((const OUString*)0), PROPERTY_UNBOUND, 0 },
diff --git a/sfx2/source/sidebar/Deck.cxx b/sfx2/source/sidebar/Deck.cxx
index 7aef1433b9c3..f3b23b48c2ef 100644
--- a/sfx2/source/sidebar/Deck.cxx
+++ b/sfx2/source/sidebar/Deck.cxx
@@ -361,7 +361,7 @@ const char* GetWindowClassification (const Window* pWindow)
}
else
{
- static char msWindow[] = "window";
+ static const char msWindow[] = "window";
return msWindow;
}
}
diff --git a/svtools/source/uno/miscservices.cxx b/svtools/source/uno/miscservices.cxx
index da5e7d248e2e..76bc5a6c7e0d 100644
--- a/svtools/source/uno/miscservices.cxx
+++ b/svtools/source/uno/miscservices.cxx
@@ -61,7 +61,7 @@ extern sdecl::ServiceDecl const serviceDecl;
namespace
{
- static struct ::cppu::ImplementationEntry s_aServiceEntries[] =
+ static const struct ::cppu::ImplementationEntry s_aServiceEntries[] =
{
{
::svt::uno::Wizard::Create,