summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/fe-common/core/formats.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/fe-common/core/formats.c b/src/fe-common/core/formats.c
index b4d2e7ed..11a932ed 100644
--- a/src/fe-common/core/formats.c
+++ b/src/fe-common/core/formats.c
@@ -995,6 +995,9 @@ void format_send_to_gui(TEXT_DEST_REC *dest, const char *text)
flags |= GUI_PRINT_FLAG_BOLD;
}
}
+ if (ptr[1] == '\0')
+ break;
+
ptr++;
if (*ptr != FORMAT_COLOR_NOCHANGE) {
bgcolor = *ptr-'0';