dive.h: add a variant of FOR_EACH_PICTURE

This prevents a warning caused by -Waddress, that the address
of 'displayed_dive' will always be defined.

Exact macro variant suggested by Dirk.

Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Lubomir I. Ivanov 2014-10-28 12:13:07 +02:00 committed by Dirk Hohndel
parent 70a2e91f1c
commit 874754e22b
2 changed files with 3 additions and 1 deletions

View file

@ -51,7 +51,7 @@ void DivePictureModel::updateDivePictures()
stringPixmapCache.clear();
QStringList pictures;
FOR_EACH_PICTURE (&displayed_dive) {
FOR_EACH_PICTURE_NON_PTR(displayed_dive) {
stringPixmapCache[QString(picture->filename)].offsetSeconds = picture->offset.seconds;
pictures.push_back(QString(picture->filename));
}