[PATCH v2 1/3] server: Replace some malloc/sprintf/strcpy calls with asprintf.