diff options
Diffstat (limited to 'audio/audio_pt_int.c')
-rw-r--r-- | audio/audio_pt_int.c | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/audio/audio_pt_int.c b/audio/audio_pt_int.c index 21ff9c5..3fe56d8 100644 --- a/audio/audio_pt_int.c +++ b/audio/audio_pt_int.c @@ -31,7 +31,7 @@ int audio_pt_init (struct audio_pt *p, void *(*func) (void *), err = sigfillset (&set); if (err) { - logerr (p, errno, "%s(%s): sigfillset failed", cap, AUDIO_FUNC); + logerr(p, errno, "%s(%s): sigfillset failed", cap, __func__); return -1; } @@ -57,8 +57,8 @@ int audio_pt_init (struct audio_pt *p, void *(*func) (void *), err2 = pthread_sigmask (SIG_SETMASK, &old_set, NULL); if (err2) { - logerr (p, err2, "%s(%s): pthread_sigmask (restore) failed", - cap, AUDIO_FUNC); + logerr(p, err2, "%s(%s): pthread_sigmask (restore) failed", + cap, __func__); /* We have failed to restore original signal mask, all bets are off, so terminate the process */ exit (EXIT_FAILURE); @@ -74,17 +74,17 @@ int audio_pt_init (struct audio_pt *p, void *(*func) (void *), err2: err2 = pthread_cond_destroy (&p->cond); if (err2) { - logerr (p, err2, "%s(%s): pthread_cond_destroy failed", cap, AUDIO_FUNC); + logerr(p, err2, "%s(%s): pthread_cond_destroy failed", cap, __func__); } err1: err2 = pthread_mutex_destroy (&p->mutex); if (err2) { - logerr (p, err2, "%s(%s): pthread_mutex_destroy failed", cap, AUDIO_FUNC); + logerr(p, err2, "%s(%s): pthread_mutex_destroy failed", cap, __func__); } err0: - logerr (p, err, "%s(%s): %s failed", cap, AUDIO_FUNC, efunc); + logerr(p, err, "%s(%s): %s failed", cap, __func__, efunc); return -1; } @@ -94,13 +94,13 @@ int audio_pt_fini (struct audio_pt *p, const char *cap) err = pthread_cond_destroy (&p->cond); if (err) { - logerr (p, err, "%s(%s): pthread_cond_destroy failed", cap, AUDIO_FUNC); + logerr(p, err, "%s(%s): pthread_cond_destroy failed", cap, __func__); ret = -1; } err = pthread_mutex_destroy (&p->mutex); if (err) { - logerr (p, err, "%s(%s): pthread_mutex_destroy failed", cap, AUDIO_FUNC); + logerr(p, err, "%s(%s): pthread_mutex_destroy failed", cap, __func__); ret = -1; } return ret; @@ -112,7 +112,7 @@ int audio_pt_lock (struct audio_pt *p, const char *cap) err = pthread_mutex_lock (&p->mutex); if (err) { - logerr (p, err, "%s(%s): pthread_mutex_lock failed", cap, AUDIO_FUNC); + logerr(p, err, "%s(%s): pthread_mutex_lock failed", cap, __func__); return -1; } return 0; @@ -124,7 +124,7 @@ int audio_pt_unlock (struct audio_pt *p, const char *cap) err = pthread_mutex_unlock (&p->mutex); if (err) { - logerr (p, err, "%s(%s): pthread_mutex_unlock failed", cap, AUDIO_FUNC); + logerr(p, err, "%s(%s): pthread_mutex_unlock failed", cap, __func__); return -1; } return 0; @@ -136,7 +136,7 @@ int audio_pt_wait (struct audio_pt *p, const char *cap) err = pthread_cond_wait (&p->cond, &p->mutex); if (err) { - logerr (p, err, "%s(%s): pthread_cond_wait failed", cap, AUDIO_FUNC); + logerr(p, err, "%s(%s): pthread_cond_wait failed", cap, __func__); return -1; } return 0; @@ -148,12 +148,12 @@ int audio_pt_unlock_and_signal (struct audio_pt *p, const char *cap) err = pthread_mutex_unlock (&p->mutex); if (err) { - logerr (p, err, "%s(%s): pthread_mutex_unlock failed", cap, AUDIO_FUNC); + logerr(p, err, "%s(%s): pthread_mutex_unlock failed", cap, __func__); return -1; } err = pthread_cond_signal (&p->cond); if (err) { - logerr (p, err, "%s(%s): pthread_cond_signal failed", cap, AUDIO_FUNC); + logerr(p, err, "%s(%s): pthread_cond_signal failed", cap, __func__); return -1; } return 0; @@ -166,7 +166,7 @@ int audio_pt_join (struct audio_pt *p, void **arg, const char *cap) err = pthread_join (p->thread, &ret); if (err) { - logerr (p, err, "%s(%s): pthread_join failed", cap, AUDIO_FUNC); + logerr(p, err, "%s(%s): pthread_join failed", cap, __func__); return -1; } *arg = ret; |