]> git.eshelyaron.com Git - emacs.git/commitdiff
(init_fringe_bitmap) [HAVE_X_WINDOWS && WORDS_BIG_ENDIAN]:
authorYAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
Sat, 25 Apr 2009 00:26:34 +0000 (00:26 +0000)
committerYAMAMOTO Mitsuharu <mituharu@math.s.chiba-u.ac.jp>
Sat, 25 Apr 2009 00:26:34 +0000 (00:26 +0000)
Swap bytes in short integer if fringe bitmap width > 8.

src/ChangeLog
src/fringe.c

index c87aeb182ee4dd8124db7e639af383ba71027234..ccd678ff8bf3254795d3a201b21ff82b2aad74f3 100644 (file)
@@ -1,3 +1,8 @@
+2009-04-25  YAMAMOTO Mitsuharu  <mituharu@math.s.chiba-u.ac.jp>
+
+       * fringe.c (init_fringe_bitmap) [HAVE_X_WINDOWS && WORDS_BIG_ENDIAN]:
+       Swap bytes in short integer if fringe bitmap width > 8.
+
 2009-04-23  Kenichi Handa  <handa@m17n.org>
 
        * xfaces.c (Fx_list_fonts): If a font size is specified in
index 9b5924145322868ca3a5375edb9c4aa25a72be1d..41fc24d1150f748b1e0439b70958de595932e6cc 100644 (file)
@@ -1369,7 +1369,11 @@ init_fringe_bitmap (which, fb, once_p)
                                   | (swap_nibble[(b>>4) & 0xf] << 8)
                                   | (swap_nibble[(b>>8) & 0xf] << 4)
                                   | (swap_nibble[(b>>12) & 0xf]));
-             *bits++ = (b >> (16 - fb->width));
+             b >>= (16 - fb->width);
+#ifdef WORDS_BIG_ENDIAN
+             b = ((b >> 8) | (b << 8));
+#endif
+             *bits++ = b;
            }
        }
 #endif /* HAVE_X_WINDOWS */