billiob pushed a commit to branch master.

http://git.enlightenment.org/apps/terminology.git/commit/?id=2b9c9a83514b433138448f63f9f3bab46ad7e629

commit 2b9c9a83514b433138448f63f9f3bab46ad7e629
Author: Boris Faure <bill...@gmail.com>
Date:   Thu May 8 13:55:01 2014 +0200

    add some padding fields to be sure holes are initialized (hi valgrind!)
---
 src/bin/termpty.c | 4 ++--
 src/bin/termpty.h | 8 +++++++-
 2 files changed, 9 insertions(+), 3 deletions(-)

diff --git a/src/bin/termpty.c b/src/bin/termpty.c
index 1eb4344..9172f00 100644
--- a/src/bin/termpty.c
+++ b/src/bin/termpty.c
@@ -1056,9 +1056,9 @@ void
 termpty_cell_codepoint_att_fill(Termpty *ty, Eina_Unicode codepoint,
                                 Termatt att, Termcell *dst, int n)
 {
-   Termcell local = { codepoint, att };
+   Termcell local = { .codepoint = codepoint, .att = att };
    int i;
-   
+
    for (i = 0; i < n; i++)
      {
         _handle_block_codepoint_overwrite(ty, dst[i].codepoint, codepoint);
diff --git a/src/bin/termpty.h b/src/bin/termpty.h
index 98febce..521e60e 100644
--- a/src/bin/termpty.h
+++ b/src/bin/termpty.h
@@ -54,7 +54,9 @@ struct _Termatt
    unsigned short italic : 1;
 #elif defined(SUPPORT_DBLWIDTH)
    unsigned short dblwidth : 1;
-#endif   
+#else
+   unsigned short bit_padding_0 : 1;
+#endif
    unsigned short underline : 1;
    unsigned short blink : 1; // don't intend to support this currently
    unsigned short blink2 : 1; // don't intend to support this currently
@@ -72,6 +74,9 @@ struct _Termatt
    unsigned short fraktur : 1;
 #if defined(SUPPORT_80_132_COLUMNS)
    unsigned short is_80_132_mode_allowed : 1;
+   unsigned short bit_padding : 14;
+#else
+   unsigned short bit_padding : 15;
 #endif
 };
 
@@ -156,6 +161,7 @@ struct _Termcell
 {
    Eina_Unicode   codepoint;
    Termatt        att;
+   unsigned char padding[2];
 };
 
 struct _Termsave

-- 


Reply via email to