1
0
mirror of https://github.com/kakwa/uts-server synced 2024-06-19 18:22:59 +02:00

adapt to create_response new API

This commit is contained in:
kakwa 2016-08-30 23:03:53 +02:00
parent d54c661eef
commit 00c91df4cf

View File

@ -88,13 +88,13 @@ int rfc3161_handler(struct mg_connection *conn, void *context) {
// Send HTTP reply to the client // Send HTTP reply to the client
if (is_tsq) { if (is_tsq) {
char *query = calloc(request_info->content_length, sizeof(char)); char *query = calloc(request_info->content_length, sizeof(char));
mg_read(conn, query, request_info->content_length); int query_len = mg_read(conn, query, request_info->content_length);
log_hex(ct, LOG_DEBUG, "query hexdump content", query, log_hex(ct, LOG_DEBUG, "query hexdump content", (unsigned char *)query,
request_info->content_length); request_info->content_length);
int ts_resp = int ts_resp = create_response(ct, query, query_len, ct->ts_ctx,
create_response(ct, query, ct->ts_ctx, &content_length, &content); &content_length, &content);
if (ts_resp) { if (ts_resp) {
log_hex(ct, LOG_DEBUG, "response hexdump content", content, log_hex(ct, LOG_DEBUG, "response hexdump content", content,
content_length); content_length);