diff options
author | markster <markster@f38db490-d61c-443f-a65b-d21fe96a405b> | 2001-04-03 18:38:37 +0000 |
---|---|---|
committer | markster <markster@f38db490-d61c-443f-a65b-d21fe96a405b> | 2001-04-03 18:38:37 +0000 |
commit | 81bd6022a7a2148e1e15c673864076746e9155e6 (patch) | |
tree | ef59618ca69feea7194e46c7392abcc10884484d /formats/format_g723.c | |
parent | 43262aded51ebe1b604c70b5aa39d48ea59a50cf (diff) |
Version 0.1.8 from FTP
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@263 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'formats/format_g723.c')
-rwxr-xr-x | formats/format_g723.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/formats/format_g723.c b/formats/format_g723.c index c437addcd..e93ed0414 100755 --- a/formats/format_g723.c +++ b/formats/format_g723.c @@ -58,7 +58,7 @@ static struct ast_filestream *g723_open(int fd) and be sure it's a valid file. */ struct ast_filestream *tmp; if ((tmp = malloc(sizeof(struct ast_filestream)))) { - if (pthread_mutex_lock(&g723_lock)) { + if (ast_pthread_mutex_lock(&g723_lock)) { ast_log(LOG_WARNING, "Unable to lock g723 list\n"); free(tmp); return NULL; @@ -78,7 +78,7 @@ static struct ast_filestream *g723_open(int fd) tmp->orig.tv_usec = 0; tmp->orig.tv_sec = 0; glistcnt++; - pthread_mutex_unlock(&g723_lock); + ast_pthread_mutex_unlock(&g723_lock); ast_update_use_count(); } return tmp; @@ -91,7 +91,7 @@ static struct ast_filestream *g723_rewrite(int fd, char *comment) and be sure it's a valid file. */ struct ast_filestream *tmp; if ((tmp = malloc(sizeof(struct ast_filestream)))) { - if (pthread_mutex_lock(&g723_lock)) { + if (ast_pthread_mutex_lock(&g723_lock)) { ast_log(LOG_WARNING, "Unable to lock g723 list\n"); free(tmp); return NULL; @@ -105,7 +105,7 @@ static struct ast_filestream *g723_rewrite(int fd, char *comment) tmp->orig.tv_usec = 0; tmp->orig.tv_sec = 0; glistcnt++; - pthread_mutex_unlock(&g723_lock); + ast_pthread_mutex_unlock(&g723_lock); ast_update_use_count(); } else ast_log(LOG_WARNING, "Out of memory\n"); @@ -120,7 +120,7 @@ static struct ast_frame *g723_read(struct ast_filestream *s) static void g723_close(struct ast_filestream *s) { struct ast_filestream *tmp, *tmpl = NULL; - if (pthread_mutex_lock(&g723_lock)) { + if (ast_pthread_mutex_lock(&g723_lock)) { ast_log(LOG_WARNING, "Unable to lock g723 list\n"); return; } @@ -143,7 +143,7 @@ static void g723_close(struct ast_filestream *s) ast_sched_del(s->owner->sched, s->owner->streamid); s->owner->streamid = -1; } - pthread_mutex_unlock(&g723_lock); + ast_pthread_mutex_unlock(&g723_lock); ast_update_use_count(); if (!tmp) ast_log(LOG_WARNING, "Freeing a filestream we don't seem to own\n"); @@ -317,7 +317,7 @@ int load_module() int unload_module() { struct ast_filestream *tmp, *tmpl; - if (pthread_mutex_lock(&g723_lock)) { + if (ast_pthread_mutex_lock(&g723_lock)) { ast_log(LOG_WARNING, "Unable to lock g723 list\n"); return -1; } @@ -329,19 +329,19 @@ int unload_module() tmp = tmp->next; free(tmpl); } - pthread_mutex_unlock(&g723_lock); + ast_pthread_mutex_unlock(&g723_lock); return ast_format_unregister(name); } int usecount() { int res; - if (pthread_mutex_lock(&g723_lock)) { + if (ast_pthread_mutex_lock(&g723_lock)) { ast_log(LOG_WARNING, "Unable to lock g723 list\n"); return -1; } res = glistcnt; - pthread_mutex_unlock(&g723_lock); + ast_pthread_mutex_unlock(&g723_lock); return res; } |