From b9d614e7dee330da81720a181a1275c15ab10e0e Mon Sep 17 00:00:00 2001 From: Sebastien Helleu Date: Sat, 6 Aug 2011 23:13:58 +0200 Subject: core: fix unwanted merge of buffers when no layout number is assigned to buffer (on /layout apply) --- src/gui/gui-layout.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src') diff --git a/src/gui/gui-layout.c b/src/gui/gui-layout.c index 52f711548..f9b2ee0cd 100644 --- a/src/gui/gui-layout.c +++ b/src/gui/gui-layout.c @@ -262,9 +262,12 @@ gui_layout_buffer_apply (struct t_gui_layout_buffer *layout_buffers) { ptr_next_buffer = ptr_buffer->next_buffer; - if (ptr_buffer->layout_number == (ptr_buffer->prev_buffer)->layout_number) + if ((ptr_buffer->layout_number >= 1) + && (ptr_buffer->layout_number == (ptr_buffer->prev_buffer)->layout_number)) + { gui_buffer_merge (ptr_buffer, ptr_buffer->prev_buffer); - + } + ptr_buffer = ptr_next_buffer; } -- cgit v1.2.3