Write start line when found
This commit is contained in:
parent
9d5bc143a2
commit
529b86dade
|
@ -71,6 +71,11 @@ static struct line_read_result read_line(const char *buffer, int buffer_size, st
|
|||
result.line = malloc((line_size + 1) * sizeof(char));
|
||||
memcpy(result.line, buffer, line_size);
|
||||
result.line[line_size] = '\0';
|
||||
if (result.line_type == RESULT_START_LINE) {
|
||||
message->start_line = malloc((line_size + 1) * sizeof(char));
|
||||
strcpy(message->start_line, result.line);
|
||||
message->start_line = result.line;
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue