logpanel: fix crash when appending lots of lines.

Surround elm_code_file_line_append() with ecore_main_loop_begin/end.
Fixes a crash when there are lots of errors to report.

@fix
This commit is contained in:
Alastair Poole 2018-05-14 10:26:20 +01:00
parent 8fafc6c00a
commit d55bea9725
1 changed files with 3 additions and 0 deletions

View File

@ -46,8 +46,11 @@ _edi_logpanel_print_cb(const Eina_Log_Domain *domain, Eina_Log_Level level,
domain->domain_str, file, fnc, line);
vsnprintf(buffer + printed, buffer_len - printed, fmt, args);
ecore_thread_main_loop_begin();
elm_code_file_line_append(_elm_code->file, buffer, strlen(buffer),
(level <= EINA_LOG_LEVEL_ERR) ? _EDI_LOG_ERROR : NULL);
ecore_thread_main_loop_end();
}
static void