[svn-commits] irroot: branch irroot/asterisk-trunk-quack-queue r345022 - /team/irroot/aster...
SVN commits to the Digium repositories
svn-commits at lists.digium.com
Sun Nov 13 03:35:07 CST 2011
Author: irroot
Date: Sun Nov 13 03:35:04 2011
New Revision: 345022
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=345022
Log:
Move datastore stuff to features.c its needed there so can live there
Modified:
team/irroot/asterisk-trunk-quack-queue/main/features.c
team/irroot/asterisk-trunk-quack-queue/main/global_datastores.c
Modified: team/irroot/asterisk-trunk-quack-queue/main/features.c
URL: http://svnview.digium.com/svn/asterisk/team/irroot/asterisk-trunk-quack-queue/main/features.c?view=diff&rev=345022&r1=345021&r2=345022
==============================================================================
--- team/irroot/asterisk-trunk-quack-queue/main/features.c (original)
+++ team/irroot/asterisk-trunk-quack-queue/main/features.c Sun Nov 13 03:35:04 2011
@@ -7194,6 +7194,10 @@
return res;
}
+const struct ast_datastore_info pickup_target_info = {
+ .type = "pickup-call",
+};
+
int ast_do_pickup(struct ast_channel *chan, struct ast_channel *target)
{
struct ast_party_connected_line connected_caller;
@@ -7216,10 +7220,9 @@
}
ast_channel_datastore_add(target, ds_pickup);
- /* Mark the target so a macro can be run on it if needed. */
- ds_bridge_macro = ast_datastore_alloc(&pickup_target_info, NULL);
- if (ds_bridge_macro) {
- ast_channel_datastore_add(target, ds_bridge_macro);
+ /* Mark the channel so with datastore that is has been picked up */
+ if ((ds_bridge_macro = ast_datastore_alloc(&pickup_target_info, NULL))) {
+ ast_channel_datastore_add(chan, ds_bridge_macro);
} else {
ast_log(LOG_WARNING,
"Unable to create channel datastore on '%s' for running macro\n", target_name);
@@ -7278,7 +7281,7 @@
if (!ast_channel_datastore_remove(target, ds_pickup)) {
ast_datastore_free(ds_pickup);
}
- if (res && ds_bridge_macro && !ast_channel_datastore_remove(target, ds_bridge_macro)) {
+ if (res && ds_bridge_macro && !ast_channel_datastore_remove(chan, ds_bridge_macro)) {
ast_datastore_free(ds_bridge_macro);
}
Modified: team/irroot/asterisk-trunk-quack-queue/main/global_datastores.c
URL: http://svnview.digium.com/svn/asterisk/team/irroot/asterisk-trunk-quack-queue/main/global_datastores.c?view=diff&rev=345022&r1=345021&r2=345022
==============================================================================
--- team/irroot/asterisk-trunk-quack-queue/main/global_datastores.c (original)
+++ team/irroot/asterisk-trunk-quack-queue/main/global_datastores.c Sun Nov 13 03:35:04 2011
@@ -110,7 +110,3 @@
.destroy = secure_call_store_destroy,
.duplicate = secure_call_store_duplicate,
};
-
-const struct ast_datastore_info pickup_target_info = {
- .type = "pickup-call",
-};
More information about the svn-commits
mailing list