-static struct ast_frame *__zt_exception(struct ast_channel *ast)
+static struct ast_frame *zt_exception(struct ast_channel *ast)
{
struct zt_pvt *p = ast->pvt->pvt;
int res;
return f;
}
-struct ast_frame *zt_exception(struct ast_channel *ast)
-{
- struct zt_pvt *p = ast->pvt->pvt;
- struct ast_frame *f;
- ast_mutex_lock(&p->lock);
- f = __zt_exception(ast);
- ast_mutex_unlock(&p->lock);
- return f;
-}
-
struct ast_frame *zt_read(struct ast_channel *ast)
{
struct zt_pvt *p = ast->pvt->pvt;
ast_mutex_unlock(&p->lock);
return &p->subs[index].f;
} else if (errno == ELAST) {
- f = __zt_exception(ast);
+ f = zt_exception(ast);
} else
ast_log(LOG_WARNING, "zt_rec: %s\n", strerror(errno));
}
}
if (res != (p->subs[index].linear ? READ_SIZE * 2 : READ_SIZE)) {
ast_log(LOG_DEBUG, "Short read (%d/%d), must be an event...\n", res, p->subs[index].linear ? READ_SIZE * 2 : READ_SIZE);
- f = __zt_exception(ast);
+ f = zt_exception(ast);
ast_mutex_unlock(&p->lock);
return f;
}