From 3343d86284998a34190ac02de116dcb7bb97aa4e Mon Sep 17 00:00:00 2001
From: Robert Timm <mail@rtti.de>
Date: Mon, 17 Apr 2017 23:22:39 +0200
Subject: [PATCH] adds TODO for text buffer change warning

---
 src/ex.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/src/ex.c b/src/ex.c
index 20e0eaa..0949f55 100644
--- a/src/ex.c
+++ b/src/ex.c
@@ -380,6 +380,16 @@ void ex_input_changed(Client *c, const char *text)
         gtk_text_buffer_get_iter_at_line(buffer, &start, 0);
         if (gtk_text_iter_forward_to_line_end(&start)) {
             gtk_text_buffer_get_end_iter(buffer, &end);
+
+            /* TODO the following line creates a GTK warning.
+             * ex_input_changed() is called from the "changed" event handler of
+             * GtkTextBuffer. Apparently it's not supported to change a text
+             * buffer in the changed handler!?
+             *
+             * Gtk-WARNING **: Invalid text buffer iterator: either the
+             * iterator is uninitialized, or the characters/pixbufs/widgets in
+             * the buffer have been modified since the iterator was created.
+             */
             gtk_text_buffer_delete(buffer, &start, &end);
         }
     }
-- 
2.20.1