fela

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

ast.c (309B)


      1 #include <string.h>
      2 #include <stdlib.h>
      3 #include "ast.h"
      4 #include "util.h"
      5 
      6 struct ast_args *
      7 append_arg(struct ast_args *args, struct ast_arg *arg) {
      8 	args->args = reallocz(args->args, ++args->argc * sizeof(struct ast_arg));
      9 	memcpy(&args->args[args->argc - 1], arg, sizeof(struct ast_arg));
     10 	return args;
     11 }