[asterisk-commits] russell: branch russell/chan_refcount r82460 - /team/russell/chan_refcount/main/
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Fri Sep 14 16:45:06 CDT 2007
Author: russell
Date: Fri Sep 14 16:45:05 2007
New Revision: 82460
URL: http://svn.digium.com/view/asterisk?view=rev&rev=82460
Log:
convert another manager action
Modified:
team/russell/chan_refcount/main/manager.c
Modified: team/russell/chan_refcount/main/manager.c
URL: http://svn.digium.com/view/asterisk/team/russell/chan_refcount/main/manager.c?view=diff&rev=82460&r1=82459&r2=82460
==============================================================================
--- team/russell/chan_refcount/main/manager.c (original)
+++ team/russell/chan_refcount/main/manager.c Fri Sep 14 16:45:05 2007
@@ -2189,18 +2189,23 @@
astman_send_error(s, m, "No channel specified");
return 0;
}
+
if (!timeout) {
astman_send_error(s, m, "No timeout specified");
return 0;
}
- c = ast_get_channel_by_name_locked(name);
- if (!c) {
+
+ if (!(c = ast_channel_get_by_name(name))) {
astman_send_error(s, m, "No such channel");
return 0;
}
+
ast_channel_setwhentohangup(c, timeout);
- ast_channel_unlock(c);
+
+ ast_channel_unref(c);
+
astman_send_ack(s, m, "Timeout Set");
+
return 0;
}
More information about the asterisk-commits
mailing list