mirror of
https://github.com/irssi/irssi.git
synced 2024-12-04 14:46:39 -05:00
Merge pull request #1281 from ailin-nemui/line-under-construction
fix assertion failure when the line does not have text (yet)
This commit is contained in:
commit
f4e64e488d
@ -238,7 +238,7 @@ void textbuffer_line2text(TEXT_BUFFER_REC *buffer, LINE_REC *line, int coloring,
|
|||||||
|
|
||||||
g_string_truncate(str, 0);
|
g_string_truncate(str, 0);
|
||||||
|
|
||||||
ptr = textbuffer_line_get_text(buffer, line);
|
if ((ptr = textbuffer_line_get_text(buffer, line)) != NULL) {
|
||||||
if (coloring == 0) {
|
if (coloring == 0) {
|
||||||
tmp = ptr;
|
tmp = ptr;
|
||||||
ptr = strip_codes(tmp);
|
ptr = strip_codes(tmp);
|
||||||
@ -247,6 +247,7 @@ void textbuffer_line2text(TEXT_BUFFER_REC *buffer, LINE_REC *line, int coloring,
|
|||||||
g_string_append(str, ptr);
|
g_string_append(str, ptr);
|
||||||
g_free(ptr);
|
g_free(ptr);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
GList *textbuffer_find_text(TEXT_BUFFER_REC *buffer, LINE_REC *startline,
|
GList *textbuffer_find_text(TEXT_BUFFER_REC *buffer, LINE_REC *startline,
|
||||||
int level, int nolevel, const char *text,
|
int level, int nolevel, const char *text,
|
||||||
|
Loading…
Reference in New Issue
Block a user