diff -rN -u old-cffi/src/types.lisp new-cffi/src/types.lisp
--- old-cffi/src/types.lisp	2005-07-14 14:35:07.000000000 +0200
+++ new-cffi/src/types.lisp	2005-08-03 21:07:32.000000000 +0200
@@ -223,7 +226,7 @@
         (let ((slot (make-struct-slot slotname offset type count)))
           (setf (gethash slotname (slots struct)) slot))
         (incf offset (* count (foreign-type-size type)))))
-    (setf (size struct) offset)
+    (setf (size struct) (adjust-for-alignment struct offset))
     (setf (find-foreign-type name) struct)))
 
 (defmacro defcstruct (name &body fields)
@@ -337,6 +340,10 @@
   "Return the alignment in bytes of a foreign type."
   (%foreign-type-alignment (canonicalize-foreign-type type)))
 
+(defmethod foreign-type-alignment ((type foreign-struct-type))
+  "Return the alignment in bytes of a foreign type."
+  (%foreign-type-alignment (canonicalize type)))
+  
 (defmethod foreign-type-size ((type symbol))
   "Return the size in bytes of a foreign type."
   (foreign-type-size (find-foreign-type type)))

