Parser: remove global variable dive_id

This variable was only used in the divinglog_dive() function. There,
it was initialized right at the beginning and therefore there seems
to be no point in conserving its value across function-calls.
Make the variable local and remove the global version.

Signed-off-by: Berthold Stoeger <bstoeger@mail.tuwien.ac.at>
This commit is contained in:
Berthold Stoeger 2018-10-14 15:09:36 +02:00 committed by Dirk Hohndel
parent 8ddbe50d29
commit b01cba13c5
3 changed files with 1 additions and 4 deletions

View file

@ -271,7 +271,7 @@ extern int divinglog_dive(void *param, int columns, char **data, char **column)
UNUSED(columns);
UNUSED(column);
int retval = 0;
int retval = 0, diveid;
sqlite3 *handle = (sqlite3 *)param;
char *err = NULL;
char get_profile_template[] = "select ProfileInt,Profile,Profile2,Profile3,Profile4,Profile5 from Logbook where ID = %d";