Removed duplicated method.

This patch removes a duplicated method: get_divenr and
get_index_for_dive. The two are exactly the same  ( if my
c is not broken, but I may be broken since I'm working like
crazy for almost 30h nonstop. ), so please take a good look
before applying this one.

[Dirk Hohndel: Tomaz took the slightly broken of the two implementations,
               so I switched that out for the correct one]

Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org>
Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Tomaz Canabrava 2013-11-16 19:21:54 -02:00 committed by Dirk Hohndel
parent ad0aa8cc49
commit 314cf4c628
4 changed files with 14 additions and 23 deletions

9
dive.c
View file

@ -2038,15 +2038,6 @@ struct dive *merge_dives(struct dive *a, struct dive *b, int offset, bool prefer
return res;
}
int get_index_for_dive(struct dive *dive) {
int i;
struct dive *d;
for_each_dive(i, d)
if (d == dive)
return i;
return -1;
}
struct dive *find_dive_including(timestamp_t when)
{
int i;