[Top][All Lists]

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

FIXED: unaligned access on DEC UNIX compile

From: Tom Kacvinsky
Subject: FIXED: unaligned access on DEC UNIX compile
Date: Wed, 28 Jun 2000 19:44:16 -0400 (EDT)

Well, the problem wasn't in the grayscale renderer.  It was in

Here is a patch.  The unaligned access occured because ulongs on axps
are 8 bytes wide, but there was a cast to ulong* on a pointer that was
accessing memory on a 4 byte boundary.

Index: grx11.c
RCS file: /cvsroot/freetype2/demos/graph/x11/grx11.c,v
retrieving revision 1.3
diff -u -r1.3 grx11.c
--- grx11.c     2000/05/16 23:44:18     1.3
+++ grx11.c     2000/06/29 07:48:52
@@ -429,7 +429,7 @@
         byte  color = *_read;
-        *(unsigned long*)_write = surface->color[color].pixel;
+        *(unsigned int*)_write = surface->color[color].pixel;
       write += target->pitch;

reply via email to

[Prev in Thread] Current Thread [Next in Thread]