X-Git-Url: http://wien.tomnetworks.com/gitweb/?a=blobdiff_plain;f=mono%2Fmetadata%2Ficall.c;h=0bfe73bd4b78bb1b1dfe2334115386d1ec63b23c;hb=1e726ce7a38a92860acab28f4427813d2ba14c13;hp=72ff703939f9d524355d79c9c9159166b054b95b;hpb=28c53a39a4630ecb719a94ee6dd6801633799a89;p=mono.git diff --git a/mono/metadata/icall.c b/mono/metadata/icall.c index 72ff703939f..0bfe73bd4b7 100644 --- a/mono/metadata/icall.c +++ b/mono/metadata/icall.c @@ -6531,6 +6531,11 @@ ves_icall_System_Environment_Exit (int result) { MONO_ARCH_SAVE_REGS; +/* FIXME: There are some cleanup hangs that should be worked out, but + * if the program is going to exit, everything will be cleaned up when + * NaCl exits anyway. + */ +#ifndef __native_client__ mono_runtime_shutdown (); /* This will kill the tp threads which cannot be suspended */ @@ -6540,6 +6545,7 @@ ves_icall_System_Environment_Exit (int result) mono_thread_suspend_all_other_threads (); mono_runtime_quit (); +#endif /* we may need to do some cleanup here... */ exit (result); @@ -7214,6 +7220,12 @@ mono_ArgIterator_IntGetNextArg (MonoArgIterator *iter) iter->args = (guint8*)(((gsize)iter->args + (align) - 1) & ~(align - 1)); #endif res.value = iter->args; +#if defined(__native_client__) && SIZEOF_REGISTER == 8 + /* Values are stored as 8 byte register sized objects, but 'value' + * is dereferenced as a pointer in other routines. + */ + res.value = (char*)res.value + 4; +#endif #if G_BYTE_ORDER != G_LITTLE_ENDIAN if (arg_size <= sizeof (gpointer)) { int dummy;