diff options
author | russell <russell@f38db490-d61c-443f-a65b-d21fe96a405b> | 2010-12-20 17:15:54 +0000 |
---|---|---|
committer | russell <russell@f38db490-d61c-443f-a65b-d21fe96a405b> | 2010-12-20 17:15:54 +0000 |
commit | c15c0120f1da9354dbfffd80d43f83c3ef372732 (patch) | |
tree | d1049b4c6e02a7236e3a64c09f10633b99decc64 /channels/chan_gtalk.c | |
parent | ef5097f7805184a21929702dd7e28cfce9dc3261 (diff) |
Some scheduler API cleanup and improvements.
Previously, I had added the ast_sched_thread stuff that was a generic scheduler
thread implementation. However, if you used it, it required using different
functions for modifying scheduler contents. This patch reworks how this is
done and just allows you to optionally start a thread on the original scheduler
context structure that has always been there. This makes it trivial to switch
to the generic scheduler thread implementation without having to touch any of
the other code that adds or removes scheduler entries.
In passing, I made some naming tweaks to add ast_ prefixes where they were not
there before.
Review: https://reviewboard.asterisk.org/r/1007/
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@299091 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels/chan_gtalk.c')
-rw-r--r-- | channels/chan_gtalk.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/channels/chan_gtalk.c b/channels/chan_gtalk.c index 9b7dd80af..280cac4b5 100644 --- a/channels/chan_gtalk.c +++ b/channels/chan_gtalk.c @@ -226,7 +226,7 @@ static const struct ast_channel_tech gtalk_tech = { static struct sockaddr_in bindaddr = { 0, }; /*!< The address we bind to */ -static struct sched_context *sched; /*!< The scheduling context */ +static struct ast_sched_context *sched; /*!< The scheduling context */ static struct io_context *io; /*!< The IO context */ static struct in_addr __ourip; @@ -2248,7 +2248,7 @@ static int load_module(void) return 0; } - sched = sched_context_create(); + sched = ast_sched_context_create(); if (!sched) { ast_log(LOG_WARNING, "Unable to create schedule context\n"); } |