summaryrefslogtreecommitdiffstats
path: root/tests/auto
diff options
context:
space:
mode:
authorJędrzej Nowacki <jedrzej.nowacki@digia.com>2012-11-02 13:59:04 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2012-11-03 11:20:26 +0100
commitfb0f58f50f30116fc72ca0e8d0fbea1331052c22 (patch)
tree8fe7dedfa9c87ff0917a51d60a276dee3964d6b2 /tests/auto
parent8fb379dc8a4d7069a99c3181283e581b86e99ceb (diff)
Fix conditional jump based on an uninitialized variable.
Valgrind warns about the jump in qfontconfigdatabase.cpp:522 based on uint QFondDef::hintingPreference:2 property. Surprising thing is that the property is initialized in the default constructor, so there should not be an issue. The warning disappear if the property is _not_ placed on a boundary of a two words, or if bit field is fully initialized. So I suspect that only one bit of the two was initialized properly. I decide to implement both solutions because of a potential minor performance improvement, during reading the property. I still fail to say why the value was uninitialized, I believe that this patch simply workarounds gcc bug or valgrind bug. Change-Id: I2e87738f66a435ef6e30b3d2db6baa73da025426 Reviewed-by: Jiang Jiang <gzjjgod@gmail.com> Reviewed-by: Eskil Abrahamsen Blomfeldt <eskil.abrahamsen-blomfeldt@digia.com> Reviewed-by: Konstantin Ritt <ritt.ks@gmail.com>
Diffstat (limited to 'tests/auto')
0 files changed, 0 insertions, 0 deletions