From fc1a90dae7267919efbb9843fb75974ea0a9e711 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=A6=8C=20=EA=A6=AB=EA=A6=B6=20=EA=A6=8F=EA=A7=80?= =?UTF-8?q?=EA=A6=A6=EA=A6=BF=20=EA=A6=A7=20=EA=A6=AE=20=EA=A6=91=20?= =?UTF-8?q?=EA=A6=A9=20=EA=A6=AD=EA=A7=80?= Date: Tue, 1 Oct 2019 23:15:52 +0800 Subject: Bypass e-mail record content for now --- ticket.c | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/ticket.c b/ticket.c index 161f079..0288498 100644 --- a/ticket.c +++ b/ticket.c @@ -160,10 +160,34 @@ static size_t history_handler(void *contents, size_t size, size_t nmemb strcpy(ticket_history->description , ++token); } else if (!strcmp(token, "Content")) { + if (ticket_history->type + == RTCLIENT_TICKET_HISTORY_TYPE_EMAIL_RECORD) { + ticket_history->content = NULL; + break; + } token = strtok_r(NULL, ":", &tokensaveptr); ticket_history->content = malloc(strlen(token)); strcpy(ticket_history->content, ++token); + /* + while ((history = strtok_r(NULL, "#" + , &historysaveptr))) { + list->length--; + char *ptr = realloc(ticket_history + ->content + , strlen + (ticket_history + ->content) + + strlen(history) + + 2); + ticket_history->content = ptr; + sprintf(ticket_history->content + , "%s#%s" + , ticket_history + ->content + , history); + } + */ while ((line = strtok_r(NULL, "\n" , &linesaveptr))) { if (!strncmp(line, "Creator", 7)) -- cgit v1.2.3