aboutsummaryrefslogtreecommitdiff
path: root/libffi
diff options
context:
space:
mode:
Diffstat (limited to 'libffi')
-rw-r--r--libffi/ChangeLog6
-rw-r--r--libffi/src/x86/ffi.c8
2 files changed, 10 insertions, 4 deletions
diff --git a/libffi/ChangeLog b/libffi/ChangeLog
index 8d0fa81..557cf7f 100644
--- a/libffi/ChangeLog
+++ b/libffi/ChangeLog
@@ -1,3 +1,9 @@
+2003-12-02 Hosaka Yuji <hos@tamanegi.org>
+
+ PR other/13221
+ * src/x86/ffi.c (ffi_prep_args, ffi_prep_incoming_args_SYSV):
+ Align arguments to 32 bits.
+
2003-12-01 Andreas Tobler <a.tobler@schweiz.ch>
PR other/13221
diff --git a/libffi/src/x86/ffi.c b/libffi/src/x86/ffi.c
index bd0874f..14b0295 100644
--- a/libffi/src/x86/ffi.c
+++ b/libffi/src/x86/ffi.c
@@ -62,8 +62,8 @@ void ffi_prep_args(char *stack, extended_cif *ecif)
size_t z;
/* Align if necessary */
- if (((*p_arg)->alignment - 1) & (unsigned) argp)
- argp = (char *) ALIGN(argp, (*p_arg)->alignment);
+ if ((sizeof(int) - 1) & (unsigned) argp)
+ argp = (char *) ALIGN(argp, sizeof(int));
z = (*p_arg)->size;
if (z < sizeof(int))
@@ -301,8 +301,8 @@ ffi_prep_incoming_args_SYSV(char *stack, void **rvalue,
size_t z;
/* Align if necessary */
- if (((*p_arg)->alignment - 1) & (unsigned) argp) {
- argp = (char *) ALIGN(argp, (*p_arg)->alignment);
+ if ((sizeof(int) - 1) & (unsigned) argp) {
+ argp = (char *) ALIGN(argp, sizeof(int));
}
z = (*p_arg)->size;