diff options
author | vkalintiris <vasilis@netdata.cloud> | 2021-03-10 10:37:47 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-10 10:37:47 +0200 |
commit | adec24dffa763654bfa8cfa9ae3bd53296c2c24f (patch) | |
tree | 63f5307373399ed797e2721fadfa2f83971a61b9 /database/rrdfamily.c | |
parent | 86ca37683eac5ffd4172c5e62652409087791999 (diff) |
Rename struct avl to avl_element and the typedef to avl_t (#10735)
Before:
```
struct foobar {
avl avl;
...
}
```
After:
```
struct foobar {
avl_t avl;
...
};
```
Which makes figuring out the type from field name easier.
Diffstat (limited to 'database/rrdfamily.c')
-rw-r--r-- | database/rrdfamily.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/database/rrdfamily.c b/database/rrdfamily.c index f75f0adc3e..3d91c37887 100644 --- a/database/rrdfamily.c +++ b/database/rrdfamily.c @@ -12,15 +12,15 @@ int rrdfamily_compare(void *a, void *b) { else return strcmp(((RRDFAMILY *)a)->family, ((RRDFAMILY *)b)->family); } -#define rrdfamily_index_add(host, rc) (RRDFAMILY *)avl_insert_lock(&((host)->rrdfamily_root_index), (avl *)(rc)) -#define rrdfamily_index_del(host, rc) (RRDFAMILY *)avl_remove_lock(&((host)->rrdfamily_root_index), (avl *)(rc)) +#define rrdfamily_index_add(host, rc) (RRDFAMILY *)avl_insert_lock(&((host)->rrdfamily_root_index), (avl_t *)(rc)) +#define rrdfamily_index_del(host, rc) (RRDFAMILY *)avl_remove_lock(&((host)->rrdfamily_root_index), (avl_t *)(rc)) static RRDFAMILY *rrdfamily_index_find(RRDHOST *host, const char *id, uint32_t hash) { RRDFAMILY tmp; tmp.family = id; tmp.hash_family = (hash)?hash:simple_hash(tmp.family); - return (RRDFAMILY *)avl_search_lock(&(host->rrdfamily_root_index), (avl *) &tmp); + return (RRDFAMILY *)avl_search_lock(&(host->rrdfamily_root_index), (avl_t *) &tmp); } RRDFAMILY *rrdfamily_create(RRDHOST *host, const char *id) { |