Lines Matching refs:server_req
1241 struct server_request *server_req = NULL; in request_parse() local
1259 server_req = mm_malloc(sizeof(struct server_request)); in request_parse()
1260 if (server_req == NULL) return -1; in request_parse()
1261 memset(server_req, 0, sizeof(struct server_request)); in request_parse()
1263 server_req->trans_id = trans_id; in request_parse()
1264 memcpy(&server_req->addr, addr, addrlen); in request_parse()
1265 server_req->addrlen = addrlen; in request_parse()
1267 server_req->base.flags = flags; in request_parse()
1268 server_req->base.nquestions = 0; in request_parse()
1269 server_req->base.questions = mm_calloc(sizeof(struct evdns_server_question *), questions); in request_parse()
1270 if (server_req->base.questions == NULL) in request_parse()
1288 server_req->base.questions[server_req->base.nquestions++] = q; in request_parse()
1293 server_req->port = port; in request_parse()
1298 evdns_server_request_respond(&(server_req->base), DNS_ERR_NOTIMPL); in request_parse()
1302 port->user_callback(&(server_req->base), port->user_data); in request_parse()
1306 if (server_req->base.questions) { in request_parse()
1307 for (i = 0; i < server_req->base.nquestions; ++i) in request_parse()
1308 mm_free(server_req->base.questions[i]); in request_parse()
1309 mm_free(server_req->base.questions); in request_parse()
1311 mm_free(server_req); in request_parse()