aboutsummaryrefslogtreecommitdiff
path: root/libffi/src/ffitest.c
diff options
context:
space:
mode:
authorJeff Sturm <jsturm@one-point.com>2003-01-03 23:08:56 +0000
committerJeff Sturm <jsturm@one-point.com>2003-01-03 23:08:56 +0000
commit0a41e495000dcdf47691bc72b2b42cbd323e4a85 (patch)
tree5d6ae28f882205c56e8f57b592354a04b05fc737 /libffi/src/ffitest.c
parent94ee7c5562384b7007ce5ac463acf649b5d50061 (diff)
* include/ffi.h.in: Add closure defines for SPARC, SPARC64.
* src/ffitest.c (main): Use static storage for closure. * src/sparc/ffi.c (ffi_prep_closure, ffi_closure_sparc_inner): New. * src/sparc/v8.S (ffi_closure_v8): New. * src/sparc/v9.S (ffi_closure_v9): New. git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@60857 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'libffi/src/ffitest.c')
-rw-r--r--libffi/src/ffitest.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/libffi/src/ffitest.c b/libffi/src/ffitest.c
index da528317bb3..0dd7688dff5 100644
--- a/libffi/src/ffitest.c
+++ b/libffi/src/ffitest.c
@@ -1,5 +1,5 @@
/* -----------------------------------------------------------------------
- ffitest.c - Copyright (c) 1996, 1997, 1998, 2002 Red Hat, Inc.
+ ffitest.c - Copyright (c) 1996, 1997, 1998, 2002, 2003 Red Hat, Inc.
Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
@@ -1044,7 +1044,9 @@ int main(/*@unused@*/ int argc, /*@unused@*/ char *argv[])
# if FFI_CLOSURES
/* A simple closure test */
{
- ffi_closure cl;
+ /* The closure must not be an automatic variable on
+ platforms (Solaris) that forbid stack execution by default. */
+ static ffi_closure cl;
ffi_type * cl_arg_types[3];
cl_arg_types[0] = &ffi_type_sint;