summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorHib Eris <hib@hiberis.nl>2013-11-15 11:38:45 +0100
committerAlbert Astals Cid <aacid@kde.org>2013-11-15 20:08:07 +0100
commita23c9ad4c0536d680bedc563444ce3adf6e1ee9e (patch)
tree52061f289fa0aa88ac1a12cf81da2fe22bdd2f79 /utils
parent33e703ac9bb6cf69664d6c6fddd3bebd56336074 (diff)
Silence warning for may be used uninitialized variable in ImageOutputDec.cc
Fixes warning: CXX ImageOutputDev.lo ImageOutputDev.cc: In member function 'void ImageOutputDev::writeImageFile(ImgWriter*, ImageOutputDev::ImageFormat, const char*, Stream*, int, int, GfxImageColorMap*)': ImageOutputDev.cc:409:28: warning: 'imgStr' may be used uninitialized in this function [-Wmaybe-uninitialized] Bug #71642
Diffstat (limited to 'utils')
-rw-r--r--utils/ImageOutputDev.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/utils/ImageOutputDev.cc b/utils/ImageOutputDev.cc
index 93ed0fe6..5de51ad5 100644
--- a/utils/ImageOutputDev.cc
+++ b/utils/ImageOutputDev.cc
@@ -22,6 +22,7 @@
// Copyright (C) 2010 Jakob Voss <jakob.voss@gbv.de>
// Copyright (C) 2012, 2013 Adrian Johnson <ajohnson@redneon.com>
// Copyright (C) 2013 Thomas Fischer <fischer@unix-ag.uni-kl.de>
+// Copyright (C) 2013 Hib Eris <hib@hiberis.nl>
//
// To see a description of the changes please see the Changelog file that
// came with your tarball or type make ChangeLog if you are building from git
@@ -316,7 +317,7 @@ void ImageOutputDev::writeRawImage(Stream *str, const char *ext) {
void ImageOutputDev::writeImageFile(ImgWriter *writer, ImageFormat format, const char *ext,
Stream *str, int width, int height, GfxImageColorMap *colorMap) {
FILE *f;
- ImageStream *imgStr;
+ ImageStream *imgStr = NULL;
unsigned char *row;
unsigned char *rowp;
Guchar *p;