X-Git-Url: http://git.eversberg.eu/gitweb.cgi?p=lcr.git;a=blobdiff_plain;f=admin_server.c;h=6b0647b243c8fa3221860a816060672a904e5193;hp=f1275a6a0ce33d66e2c72df1b727462d4fff845e;hb=cbe9d412a37e75b61cc74e8a65b0293923eb5160;hpb=b5427b9c694cc2c0c1e5361d4cba721c87ad1cac diff --git a/admin_server.c b/admin_server.c index f1275a6..6b0647b 100644 --- a/admin_server.c +++ b/admin_server.c @@ -107,7 +107,7 @@ void free_connection(struct admin_list *admin) memset(¶m, 0, sizeof(param)); param.disconnectinfo.cause = CAUSE_OUTOFORDER; param.disconnectinfo.location = LOCATION_PRIVATE_LOCAL; - ((class JoinRemote *)join)->message_remote(0, MESSAGE_RELEASE, ¶m); + ((class JoinRemote *)join)->message_remote(MESSAGE_RELEASE, ¶m); /* join is now destroyed, so we go to next join */ } join = joinnext; @@ -511,7 +511,7 @@ int admin_call(struct admin_list *admin, struct admin_message *msg) class Endpoint *epoint; class EndpointAppPBX *apppbx; - if (!(epoint = new Endpoint(0, 0, 0))) + if (!(epoint = new Endpoint(0, 0))) FATAL("No memory for Endpoint instance\n"); if (!(epoint->ep_app = apppbx = new DEFAULT_ENDPOINT_APP(epoint))) FATAL("No memory for Endpoint Application instance\n"); @@ -641,6 +641,17 @@ int admin_message_to_join(struct admin_msg *msg, char *remote_name, int sock_id) return(0); } + /* bchannel message + * no ref given for *_ack */ + if (msg->type == MESSAGE_BCHANNEL) + if (msg->param.bchannel.type == BCHANNEL_ASSIGN_ACK + || msg->param.bchannel.type == BCHANNEL_REMOVE_ACK) + { + /* no ref, but address */ + message_bchannel_from_join(NULL, msg->param.bchannel.type, msg->param.bchannel.addr); + return(0); + } + /* check for ref */ if (!msg->ref) { @@ -675,7 +686,7 @@ int admin_message_to_join(struct admin_msg *msg, char *remote_name, int sock_id) } /* send message */ - ((class JoinRemote *)join)->message_remote(msg->ref, msg->type, &msg->param); + ((class JoinRemote *)join)->message_remote(msg->type, &msg->param); return(0); }