diff options
Diffstat (limited to 'src/select/properties/counter_increment.c')
-rw-r--r-- | src/select/properties/counter_increment.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/select/properties/counter_increment.c b/src/select/properties/counter_increment.c index 644607b..9888e0a 100644 --- a/src/select/properties/counter_increment.c +++ b/src/select/properties/counter_increment.c @@ -14,14 +14,14 @@ #include "select/properties/properties.h" #include "select/properties/helpers.h" -css_error css__cascade_counter_increment(uint32_t opv, css_style *style, +css_error css__cascade_counter_increment(uint32_t opv, css_style *style, css_select_state *state) -{ - return css__cascade_counter_increment_reset(opv, style, state, +{ + return css__cascade_counter_increment_reset(opv, style, state, set_counter_increment); } -css_error css__set_counter_increment_from_hint(const css_hint *hint, +css_error css__set_counter_increment_from_hint(const css_hint *hint, css_computed_style *style) { css_computed_counter *item; @@ -44,7 +44,7 @@ css_error css__set_counter_increment_from_hint(const css_hint *hint, css_error css__initial_counter_increment(css_select_state *state) { - return set_counter_increment(state->computed, + return set_counter_increment(state->computed, CSS_COUNTER_INCREMENT_NONE, NULL); } @@ -57,7 +57,7 @@ css_error css__compose_counter_increment(const css_computed_style *parent, uint8_t type = get_counter_increment(child, &items); if ((child->i.uncommon == NULL && parent->i.uncommon != NULL) || - type == CSS_COUNTER_INCREMENT_INHERIT || + type == CSS_COUNTER_INCREMENT_INHERIT || (child->i.uncommon != NULL && result != child)) { size_t n_items = 0; css_computed_counter *copy = NULL; @@ -73,12 +73,12 @@ css_error css__compose_counter_increment(const css_computed_style *parent, for (i = items; i->name != NULL; i++) n_items++; - copy = malloc((n_items + 1) * + copy = malloc((n_items + 1) * sizeof(css_computed_counter)); if (copy == NULL) return CSS_NOMEM; - memcpy(copy, items, (n_items + 1) * + memcpy(copy, items, (n_items + 1) * sizeof(css_computed_counter)); } |