Initialize variable to avoid false positive in coverity

We now that plotInfo.nr will always be positive. Still, this is cheap and
shuts up the "defect".

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2015-06-21 21:35:04 -07:00
parent c01c35ca0c
commit 52ee5f28c2

View file

@ -1151,7 +1151,7 @@ struct plot_data *ProfileWidget2::getEntryFromPos(QPointF pos)
{
// find the time stamp corresponding to the mouse position
int seconds = timeAxis->valueAt(pos);
struct plot_data *entry;
struct plot_data *entry = NULL;
for (int i = 0; i < plotInfo.nr; i++) {
entry = plotInfo.entry + i;