Skip to content

Commit

Permalink
Handled compiler warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
ftrebien committed Oct 9, 2020
1 parent 0cdbba9 commit 764f188
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions rating.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ rating_action_rate_helper(DB_plugin_action_t *action, int ctx, int rating)
const char *dec = deadbeef->pl_find_meta_raw(it, ":DECODER");
char decoder_id[100];
if (dec) {
strncpy(decoder_id, dec, sizeof(decoder_id));
snprintf(decoder_id, sizeof(decoder_id), "%s\n", dec);
}
int match = it && dec;
deadbeef->pl_unlock();
Expand Down Expand Up @@ -103,73 +103,73 @@ rating_action_rate_helper(DB_plugin_action_t *action, int ctx, int rating)
}

static int
rating_action_rate0(DB_plugin_action_t *action, int ctx)
rating_action_rate0(DB_plugin_action_t *action, ddb_action_context_t ctx)
{
return rating_action_rate_helper(action, ctx, 0);
}

static int
rating_action_rate0h(DB_plugin_action_t *action, int ctx)
rating_action_rate0h(DB_plugin_action_t *action, ddb_action_context_t ctx)
{
return rating_action_rate_helper(action, ctx, 10);
}

static int
rating_action_rate1(DB_plugin_action_t *action, int ctx)
rating_action_rate1(DB_plugin_action_t *action, ddb_action_context_t ctx)
{
return rating_action_rate_helper(action, ctx, 20);
}

static int
rating_action_rate1h(DB_plugin_action_t *action, int ctx)
rating_action_rate1h(DB_plugin_action_t *action, ddb_action_context_t ctx)
{
return rating_action_rate_helper(action, ctx, 30);
}

static int
rating_action_rate2(DB_plugin_action_t *action, int ctx)
rating_action_rate2(DB_plugin_action_t *action, ddb_action_context_t ctx)
{
return rating_action_rate_helper(action, ctx, 40);
}

static int
rating_action_rate2h(DB_plugin_action_t *action, int ctx)
rating_action_rate2h(DB_plugin_action_t *action, ddb_action_context_t ctx)
{
return rating_action_rate_helper(action, ctx, 50);
}

static int
rating_action_rate3(DB_plugin_action_t *action, int ctx)
rating_action_rate3(DB_plugin_action_t *action, ddb_action_context_t ctx)
{
return rating_action_rate_helper(action, ctx, 60);
}

static int
rating_action_rate3h(DB_plugin_action_t *action, int ctx)
rating_action_rate3h(DB_plugin_action_t *action, ddb_action_context_t ctx)
{
return rating_action_rate_helper(action, ctx, 70);
}

static int
rating_action_rate4(DB_plugin_action_t *action, int ctx)
rating_action_rate4(DB_plugin_action_t *action, ddb_action_context_t ctx)
{
return rating_action_rate_helper(action, ctx, 80);
}

static int
rating_action_rate4h(DB_plugin_action_t *action, int ctx)
rating_action_rate4h(DB_plugin_action_t *action, ddb_action_context_t ctx)
{
return rating_action_rate_helper(action, ctx, 90);
}

static int
rating_action_rate5(DB_plugin_action_t *action, int ctx)
rating_action_rate5(DB_plugin_action_t *action, ddb_action_context_t ctx)
{
return rating_action_rate_helper(action, ctx, 100);
}

static int
rating_action_remove(DB_plugin_action_t *action, int ctx)
rating_action_remove(DB_plugin_action_t *action, ddb_action_context_t ctx)
{
return rating_action_rate_helper(action, ctx, -1);
}
Expand Down

0 comments on commit 764f188

Please sign in to comment.