Skip to content
Snippets Groups Projects
Commit 18307272 authored by Emmanuel Lepage Vallée's avatar Emmanuel Lepage Vallée Committed by Stepan Salenikovich
Browse files

securityeval: Pre-initialize counter array


It *is* initialized, but some compilers fail to see that and
print a scary warning.

Change-Id: I2f92767f6c0e5186112e814c160841523dbdac5e
Reviewed-by: default avatarStepan Salenikovich <stepan.salenikovich@savoirfairelinux.com>
parent db880264
No related branches found
No related tags found
No related merge requests found
...@@ -724,7 +724,7 @@ void SecurityEvaluationModelPrivate::updateReal() ...@@ -724,7 +724,7 @@ void SecurityEvaluationModelPrivate::updateReal()
typedef SecurityEvaluationModel::Severity Severity ; typedef SecurityEvaluationModel::Severity Severity ;
typedef SecurityEvaluationModel::SecurityLevel SecurityLevel; typedef SecurityEvaluationModel::SecurityLevel SecurityLevel;
int countCache[enum_class_size<SecurityEvaluationModel::Severity>()]; int countCache[enum_class_size<SecurityEvaluationModel::Severity>()] = {};
//Reset the counter //Reset the counter
for (const Severity s : EnumIterator<Severity>()) { for (const Severity s : EnumIterator<Severity>()) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment