Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 65853 Details for
Bug 102396
dev-libs/glib: apply fbsd patches
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
glib-2.6.5-fbsd.patch
glib-2.6.5-fbsd.patch (text/plain), 1.89 KB, created by
Diego Elio Pettenò (RETIRED)
on 2005-08-13 09:25:26 UTC
(
hide
)
Description:
glib-2.6.5-fbsd.patch
Filename:
MIME Type:
Creator:
Diego Elio Pettenò (RETIRED)
Created:
2005-08-13 09:25:26 UTC
Size:
1.89 KB
patch
obsolete
>diff -ur glib-2.6.5/gthread/gthread-posix.c glib-2.6.5-fbsd/gthread/gthread-posix.c >--- glib-2.6.5/gthread/gthread-posix.c 2005-06-09 17:27:13.000000000 +0200 >+++ glib-2.6.5-fbsd/gthread/gthread-posix.c 2005-08-13 18:12:54.000000000 +0200 >@@ -115,7 +115,11 @@ > # define PRIORITY_NORMAL_VALUE priority_normal_value > #endif /* POSIX_MIN_PRIORITY && POSIX_MAX_PRIORITY */ > >+#define G_THREAD_STACK_SIZE32 (1*1024*1024) >+#define G_THREAD_STACK_SIZE64 (2*1024*1024) >+ > static gulong g_thread_min_stack_size = 0; >+static gulong g_thread_default_stack_size = 0; > > #define G_MUTEX_SIZE (sizeof (pthread_mutex_t)) > >@@ -125,7 +129,8 @@ > g_thread_impl_init(void) > { > #ifdef _SC_THREAD_STACK_MIN >- g_thread_min_stack_size = MAX (sysconf (_SC_THREAD_STACK_MIN), 0); >+ g_thread_min_stack_size = MAX (sysconf (_SC_THREAD_STACK_MIN), >+ g_thread_min_stack_size); > #endif /* _SC_THREAD_STACK_MIN */ > #ifdef HAVE_PRIORITIES > # ifdef G_THREADS_IMPL_POSIX >@@ -176,7 +181,7 @@ > result = pthread_mutex_trylock ((pthread_mutex_t *) mutex); > > #ifdef G_THREADS_IMPL_POSIX >- if (result == EBUSY) >+ if ((result == EBUSY) || (result == EDEADLK)) > return FALSE; > #else /* G_THREADS_IMPL_DCE */ > if (result == 0) >@@ -309,8 +314,16 @@ > stack_size = MAX (g_thread_min_stack_size, stack_size); > /* No error check here, because some systems can't do it and > * we simply don't want threads to fail because of that. */ >- pthread_attr_setstacksize (&attr, stack_size); > } >+ else >+ { >+ if (sizeof(void *) == 8) >+ g_thread_default_stack_size = G_THREAD_STACK_SIZE64; >+ else >+ g_thread_default_stack_size = G_THREAD_STACK_SIZE32; >+ stack_size = MAX (g_thread_min_stack_size, g_thread_default_stack_size); >+ } >+ pthread_attr_setstacksize (&attr, stack_size); > #endif /* HAVE_PTHREAD_ATTR_SETSTACKSIZE */ > > #ifdef PTHREAD_SCOPE_SYSTEM >Only in glib-2.6.5-fbsd/gthread: gthread-posix.c.orig
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 102396
: 65853