ffitest.c (main): Only use ffi_closures if those are supported.
authorAndreas Jaeger <aj@suse.de>
Tue, 14 Jan 2003 09:50:48 +0000 (10:50 +0100)
committerAndreas Jaeger <aj@gcc.gnu.org>
Tue, 14 Jan 2003 09:50:48 +0000 (10:50 +0100)
* src/ffitest.c (main): Only use ffi_closures if those are
supported.

From-SVN: r61273

libffi/ChangeLog
libffi/src/ffitest.c

index 944206fe1cbec1933709d55ab87bdd6b0b0ab0aa..97705f1bfdd001c28db74546d089c0fd9f8899b0 100644 (file)
@@ -1,3 +1,8 @@
+2003-01-14  Andreas Jaeger  <aj@suse.de>
+
+       * src/ffitest.c (main): Only use ffi_closures if those are
+       supported.
+
 2003-01-13 Andreas Tobler <a.tobler@schweiz.ch>
 
        * libffi/src/ffitest.c
index 94643d9ec71503fe74139e11d205184989585e18..a05b746865d1c7cbc5f0009081508ca448e51153 100644 (file)
@@ -426,10 +426,12 @@ int main(/*@unused@*/ int argc, /*@unused@*/ char *argv[])
   ffi_arg rint;
   long long rlonglong;
 
+# if FFI_CLOSURES
   /* The closure must not be an automatic variable on
      platforms (Solaris) that forbid stack execution by default. */
   static ffi_closure cl;
-  
+#endif
+
   ffi_type * cl_arg_types[17];
 
   ffi_type ts1_type;