summaryrefslogtreecommitdiff
path: root/cppcanvas
diff options
context:
space:
mode:
authorTor Lillqvist <tlillqvist@suse.com>2013-03-19 10:43:45 +0200
committerMichael Stahl <mstahl@redhat.com>2013-05-30 22:51:22 +0200
commit8334231910df9666d1f156c798108894df572765 (patch)
tree1bc89151fd4cdccf35bc47a1206031a156edda66 /cppcanvas
parentac6ff2f372b89ac8842d7e96ff243d61fafb5aec (diff)
WaE: Potentially uninitialized local variable
(cherry picked from commit fe8eba5faa59ddf9ee82f3eb009daac72a0ec846) Conflicts: cppcanvas/source/mtfrenderer/emfplus.cxx Change-Id: I497c30dfd951132fe2f7998a158b6c14efe5ebf7
Diffstat (limited to 'cppcanvas')
-rw-r--r--cppcanvas/source/mtfrenderer/emfplus.cxx9
1 files changed, 8 insertions, 1 deletions
diff --git a/cppcanvas/source/mtfrenderer/emfplus.cxx b/cppcanvas/source/mtfrenderer/emfplus.cxx
index 81f7eb7de01b..4282c47e9ab7 100644
--- a/cppcanvas/source/mtfrenderer/emfplus.cxx
+++ b/cppcanvas/source/mtfrenderer/emfplus.cxx
@@ -1334,7 +1334,14 @@ namespace cppcanvas
case EmfPlusRecordTypeDrawEllipse:
case EmfPlusRecordTypeFillEllipse:
{
- sal_uInt32 brushIndexOrColor;
+ // Intentionally very bogus initial value
+ // to avoid MSVC complaining about
+ // potentially uninitialized local
+ // variable. As long as the code stays as
+ // intended, this variable will be
+ // assigned a (real) value in the case
+ // when it is later used.
+ sal_uInt32 brushIndexOrColor = 1234567;
if ( type == EmfPlusRecordTypeFillEllipse )
rMF >> brushIndexOrColor;