Changeset 686544b in subsurface


Ignore:
Timestamp:
Dec 29, 2017, 9:14:20 AM (3 weeks ago)
Author:
Dirk Hohndel <dirk@…>
Branches:
master
Children:
ba81348
Parents:
2fb5a7d
git-author:
Jan Mulder <jlmulder@…> (12/28/17 10:20:04)
git-committer:
Dirk Hohndel <dirk@…> (12/29/17 09:14:20)
Message:

cleanup: Improper use of negative value

CID 45112

Signed-off-by: Jan Mulder <jlmulder@…>

File:
1 edited

Legend:

Unmodified
Added
Removed
  • desktop-widgets/undocommands.cpp

    r9021a44 r686544b  
    6363                }
    6464                //delete the dive
    65                 delete_single_dive(get_divenr(diveList.at(i)));
     65                int nr;
     66                if ((nr = get_divenr(diveList.at(i))) >= 0)
     67                        delete_single_dive(nr);
    6668        }
    6769        mark_divelist_changed(true);
Note: See TracChangeset for help on using the changeset viewer.