Event name should be a const char *

This avoids a possible warning when calling this function with a string
literal as second argument.

Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
This commit is contained in:
Dirk Hohndel 2015-03-11 11:15:03 -07:00
parent 22eb8e0617
commit ddff93f096
2 changed files with 2 additions and 2 deletions

2
dive.h
View file

@ -811,7 +811,7 @@ void dump_plan(struct diveplan *diveplan);
int plan(struct diveplan *diveplan, char **cached_datap, bool is_planner, bool show_disclaimer);
void delete_single_dive(int idx);
struct event *get_next_event(struct event *event, char *name);
struct event *get_next_event(struct event *event, const char *name);
/* these structs holds the information that

View file

@ -336,7 +336,7 @@ int get_cylinder_index(struct dive *dive, struct event *ev)
return best;
}
struct event *get_next_event(struct event *event, char *name)
struct event *get_next_event(struct event *event, const char *name)
{
if (!name || !*name)
return NULL;