[template-glib] tokeninputstream: try harder to suppress extraneous newlines



commit 593325f915f6bf64e58f890af8c461a298a334ea
Author: Christian Hergert <chergert redhat com>
Date:   Mon Oct 23 18:15:55 2017 -0700

    tokeninputstream: try harder to suppress extraneous newlines
    
    Keeping the output succinct is fairly important to good template output.
    This tries a bit harder to suppress extra newlines and it very well might
    take some additional tweaking. But it doesn't seem to break any of the
    test applications so far.

 src/tmpl-token-input-stream.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/src/tmpl-token-input-stream.c b/src/tmpl-token-input-stream.c
index bf70f37..cf381d5 100644
--- a/src/tmpl-token-input-stream.c
+++ b/src/tmpl-token-input-stream.c
@@ -309,7 +309,7 @@ tmpl_token_input_stream_read_token (TmplTokenInputStream  *self,
   if (!(text = tmpl_token_input_stream_read_tag (self, &len, cancellable, error)))
     return NULL;
 
-  self->swallow_newline = self->last_was_text_with_newline;
+  self->swallow_newline = TRUE;
   self->last_was_text_with_newline = FALSE;
 
   return tmpl_token_new_generic (text);


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