From 421ae6e8c5892b8b1480da9f364fa0459ecf0b0a Mon Sep 17 00:00:00 2001 From: Andreas Schwab Date: Sun, 9 Dec 2001 15:29:01 +0000 Subject: [PATCH] (display_mode_element): Don't read past end of string if it ends with '%'. --- src/ChangeLog | 5 +++++ src/xdisp.c | 2 ++ 2 files changed, 7 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index 12ff31e6758..cfa1c2ac5fa 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2001-12-09 Andreas Schwab + + * xdisp.c (display_mode_element): Don't read past end of string if + it ends with '%'. + 2001-12-06 Eli Zaretskii * xterm.c (x_free_frame_resources) [USE_X_TOOLKIT]: Remove all the diff --git a/src/xdisp.c b/src/xdisp.c index 6ff8e9c1cde..bf984778d4a 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -13595,6 +13595,8 @@ display_mode_element (it, depth, field_width, precision, elt) } } } + else /* c == 0 */ + break; } } } -- 2.39.2