stats: Add OSMO prefix to STAT_ITEM_NOVALUE_ID

This symbol is globally visible and therefore should have an OSMO
prefix like the other identifiers exported by stat_item.h.

Sponsored-by: On-Waves ehf
This commit is contained in:
Jacob Erlbeck 2015-12-08 10:29:16 +01:00
parent af5bad5ed0
commit ac4ed17dbd
2 changed files with 4 additions and 4 deletions

View File

@ -12,7 +12,7 @@
struct osmo_stat_item_desc;
#define STAT_ITEM_NOVALUE_ID 0
#define OSMO_STAT_ITEM_NOVALUE_ID 0
#define OSMO_STAT_ITEM_NO_UNIT NULL
struct osmo_stat_item_value {

View File

@ -105,7 +105,7 @@ struct osmo_stat_item_group *osmo_stat_item_group_alloc(void *ctx,
for (i = 0; i <= item->last_offs; i++) {
item->values[i].value = desc->item_desc[item_idx].default_value;
item->values[i].id = STAT_ITEM_NOVALUE_ID;
item->values[i].id = OSMO_STAT_ITEM_NOVALUE_ID;
}
}
@ -128,7 +128,7 @@ void osmo_stat_item_set(struct osmo_stat_item *item, int32_t value)
item->last_offs = 0;
global_value_id += 1;
if (global_value_id == STAT_ITEM_NOVALUE_ID)
if (global_value_id == OSMO_STAT_ITEM_NOVALUE_ID)
global_value_id += 1;
item->values[item->last_offs].value = value;
@ -147,7 +147,7 @@ int osmo_stat_item_get_next(const struct osmo_stat_item *item, int32_t *next_idx
next_value = &item->values[next_offs];
while (next_value->id - *next_idx >= 0 &&
next_value->id != STAT_ITEM_NOVALUE_ID)
next_value->id != OSMO_STAT_ITEM_NOVALUE_ID)
{
item_value = next_value;