summaryrefslogtreecommitdiffstats
path: root/config.tests
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@kdab.com>2016-09-15 17:58:59 +0200
committerThiago Macieira <thiago.macieira@intel.com>2016-09-16 04:12:03 +0000
commit47d064e905de29153d3930dfbbe9b07cd2aa0e05 (patch)
tree678b870e1301271fdef46625e4ab630959e79f10 /config.tests
parentf1e87dc9bcc1f9d12183736dfa29a46df5930088 (diff)
libjpeg config test: init variable
Yes, yes, this is just a configure test, but why do something stupid in the code and then have to shut up Coverity manually? Fix by making it a global, which means it will be zero-initialized (I didn't want to do the obvious = 0, as that could protentially create a "0 used as nullptr" warning at some point in the future. Coverity-Id: 59485 Change-Id: I49ecd28be983a0e42b420d20da0db34a872c6f44 Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'config.tests')
-rw-r--r--config.tests/unix/libjpeg/libjpeg.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/config.tests/unix/libjpeg/libjpeg.cpp b/config.tests/unix/libjpeg/libjpeg.cpp
index 68c11e1335..4432603b84 100644
--- a/config.tests/unix/libjpeg/libjpeg.cpp
+++ b/config.tests/unix/libjpeg/libjpeg.cpp
@@ -37,9 +37,10 @@ extern "C" {
#include <jpeglib.h>
}
+j_compress_ptr cinfo;
+
int main(int, char **)
{
- j_compress_ptr cinfo;
jpeg_create_compress(cinfo);
return 0;
}