20 lines
691 B
Plaintext
20 lines
691 B
Plaintext
$OpenBSD: patch-openbox_frame_c,v 1.1 2017/09/15 18:06:20 dcoppa Exp $
|
|
|
|
From b0ed75ee851121ad25491ef6e1dca25be7bc50f3
|
|
From: o9000 <mrovi9000@gmail.com>
|
|
Date: Wed, 5 Apr 2017 12:38:10 +0200
|
|
Subject: [PATCH] Fix out-of-bounds read
|
|
|
|
Index: openbox/frame.c
|
|
--- openbox/frame.c.orig
|
|
+++ openbox/frame.c
|
|
@@ -1215,7 +1215,7 @@ static void layout_title(ObFrame *self)
|
|
}
|
|
|
|
/* stop at the end of the string (or the label, which calls break) */
|
|
- for (; *lc != '\0' && lc >= config_title_layout; lc+=i) {
|
|
+ for (; lc >= config_title_layout && *lc != '\0'; lc+=i) {
|
|
if (*lc == 'L') {
|
|
if (i > 0) {
|
|
self->label_on = TRUE;
|