Use xmalloc() instead of malloc().

This commit is contained in:
Martin Mares 2000-04-20 22:55:32 +00:00
parent 7787ace61a
commit f33c6c6602

View file

@ -297,7 +297,7 @@ cmd_expand(char *cmd)
puts("No such command."); puts("No such command.");
return NULL; return NULL;
} }
b = malloc(strlen(n->cmd->command) + strlen(args) + 1); b = xmalloc(strlen(n->cmd->command) + strlen(args) + 1);
sprintf(b, "%s%s", n->cmd->command, args); sprintf(b, "%s%s", n->cmd->command, args);
return b; return b;
} }