From: Terry Wilson Date: Thu, 24 Feb 2011 17:42:16 +0000 (+0000) Subject: Don't broadcast FullyBooted to every AMI connection X-Git-Tag: 1.4.42-rc1~47 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e90101cecf75a650afb4d51b0b9bd0085cc55418;p=thirdparty%2Fasterisk.git Don't broadcast FullyBooted to every AMI connection The FullyBooted event should not be sent to every AMI connection every time someone connects via AMI. It should only be sent to the user who just connected. (closes issue #18168) Reported by: FeyFre Patches: bug0018168.patch uploaded by FeyFre (license 1142) Tested by: FeyFre, twilson git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@308813 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/main/manager.c b/main/manager.c index eb066ab4c2..700cdd8ebe 100644 --- a/main/manager.c +++ b/main/manager.c @@ -2315,7 +2315,12 @@ static int process_message(struct mansession *s, const struct message *m) (s->session->sessiontimeout ? "HTTP " : ""), s->session->username, ast_inet_ntoa(s->session->sin.sin_addr)); astman_send_ack(s, m, "Authentication accepted"); if (ast_opt_send_fullybooted && ast_test_flag(&ast_options, AST_OPT_FLAG_FULLY_BOOTED)) { - manager_event(EVENT_FLAG_SYSTEM, "FullyBooted", "Status: Fully Booted\r\n"); + char auth[80]; + authority_to_str(EVENT_FLAG_SYSTEM, auth, sizeof(auth)); + astman_append(s, "Event: FullyBooted\r\n" + "Privilege: %s\r\n" + "Status: Fully Booted\r\n\r\n", + auth); } } } else if (!strcasecmp(action, "Logoff")) {