[Mono-dev] Patch for io-layer/collection.c
Zoltan Varga
vargaz at gmail.com
Mon May 11 18:52:49 EDT 2009
Hi,
This should be fixed now by removing all the #ifdefs and simply returning
NULL.
Zoltan
On Tue, May 12, 2009 at 12:35 AM, Koushik K. Dutta
<koush at koushikdutta.com>wrote:
> Android’s build uses the GNU C compiler, but is failing while compiling
> “gpointer collection_thread (gpointer unused G_GNUC_UNUSED)” because it
> exits via a pthread_exit, and not via the return statement:
>
> static gpointer collection_thread (gpointer unused G_GNUC_UNUSED)
> {
> struct timespec sleepytime;
>
> sleepytime.tv_sec = _WAPI_HANDLE_COLLECTION_UPDATE_INTERVAL;
> sleepytime.tv_nsec = 0;
>
> while (_wapi_has_shut_down == FALSE) {
> nanosleep (&sleepytime, NULL);
>
> //_wapi_handle_dump ();
> _wapi_handle_update_refs ();
>
> /* This is an abuse of the collection thread, but it's
> * better than creating a new thread just for one more
> * function.
> */
> _wapi_process_reap ();
> }
>
> pthread_exit (NULL);
>
> #if !defined(__GNUC__)
> /* Even though we tell gcc that this function doesn't return,
> * other compilers won't see that.
> */
> return(NULL);
> #endif
> }
>
> I’ve attached a patch that fixes the Android build by adding another
> condition to the #if.
>
> Koush
>
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.ximian.com/pipermail/mono-devel-list/attachments/20090512/19595557/attachment.html
More information about the Mono-devel-list
mailing list