Signed-off-by: Thiago Farina <tfransosi@xxxxxxxxx> --- attr.c | 8 ++------ 1 files changed, 2 insertions(+), 6 deletions(-) diff --git a/attr.c b/attr.c index 6aff695..fdc0515 100644 --- a/attr.c +++ b/attr.c @@ -305,12 +305,8 @@ static void handle_attr_line(struct attr_stack *res, a = parse_attr_line(line, src, lineno, macro_ok); if (!a) return; - if (res->alloc <= res->num_matches) { - res->alloc = alloc_nr(res->num_matches); - res->attrs = xrealloc(res->attrs, - sizeof(struct match_attr *) * - res->alloc); - } + + ALLOC_GROW(res->attrs, res->num_matches + 1, res->alloc); res->attrs[res->num_matches++] = a; } -- 1.7.3.2.343.g7d43d -- To unsubscribe from this list: send the line "unsubscribe git" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html