diff options
author | unknown <istruewing@chilla.local> | 2007-03-28 16:23:44 +0200 |
---|---|---|
committer | unknown <istruewing@chilla.local> | 2007-03-28 16:23:44 +0200 |
commit | 8f93150d20e9af978c43deb4f90cc21457bd29db (patch) | |
tree | ddb8eae409cc02ad20aeed6d597552836232bdd4 /mysys/my_pthread.c | |
parent | a79e08a6e109982688cf37e5486282aa2af2a18d (diff) | |
download | mariadb-git-8f93150d20e9af978c43deb4f90cc21457bd29db.tar.gz |
restored run-time thread lib detection
sql/stacktrace.c:
removed code duplication
sql/stacktrace.h:
removed code duplication
Diffstat (limited to 'mysys/my_pthread.c')
-rw-r--r-- | mysys/my_pthread.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/mysys/my_pthread.c b/mysys/my_pthread.c index 74ba98c321a..db01602f4ab 100644 --- a/mysys/my_pthread.c +++ b/mysys/my_pthread.c @@ -31,6 +31,8 @@ uint thd_lib_detected= 0; +uint thd_lib_detected; + #ifndef my_pthread_setprio void my_pthread_setprio(pthread_t thread_id,int prior) { @@ -51,8 +53,6 @@ int my_pthread_getprio(pthread_t thread_id) int policy; if (!pthread_getschedparam(thread_id,&policy,&tmp_sched_param)) { - DBUG_PRINT("thread",("policy: %d priority: %d", - policy,tmp_sched_param.sched_priority)); return tmp_sched_param.sched_priority; } #endif @@ -314,8 +314,6 @@ void sigwait_handle_sig(int sig) pthread_mutex_unlock(&LOCK_sigwait); } -extern pthread_t alarm_thread; - void *sigwait_thread(void *set_arg) { sigset_t *set=(sigset_t*) set_arg; @@ -334,7 +332,9 @@ void *sigwait_thread(void *set_arg) sigaction(i, &sact, (struct sigaction*) 0); } } - sigaddset(set,THR_CLIENT_ALARM); + /* Ensure that init_thr_alarm() is called */ + DBUG_ASSERT(thr_client_alarm); + sigaddset(set, thr_client_alarm); pthread_sigmask(SIG_UNBLOCK,(sigset_t*) set,(sigset_t*) 0); alarm_thread=pthread_self(); /* For thr_alarm */ |