[gnome-builder] auto-indent: check the iteration character for match



commit 88729b6adf8d518250dbbdbd476a8bcda0ad7e7b
Author: Christian Hergert <christian hergert me>
Date:   Wed Oct 15 17:57:40 2014 -0700

    auto-indent: check the iteration character for match
    
    We were checking the input character, which would never change. Make sure
    we match against the iter position.

 src/editor/gb-source-auto-indenter-c.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/editor/gb-source-auto-indenter-c.c b/src/editor/gb-source-auto-indenter-c.c
index a7aadb5..6af20dc 100644
--- a/src/editor/gb-source-auto-indenter-c.c
+++ b/src/editor/gb-source-auto-indenter-c.c
@@ -281,7 +281,7 @@ backward_to_line_first_char (GtkTextIter *iter)
        gtk_text_iter_compare (&tmp, iter) < 0;
        gtk_text_iter_forward_char (&tmp))
     {
-      if (!g_unichar_isspace (gtk_text_iter_get_char (iter)))
+      if (!g_unichar_isspace (gtk_text_iter_get_char (&tmp)))
         {
           gtk_text_iter_assign (iter, &tmp);
           return TRUE;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]