Properly install appropriate sound files, prefix spy ones with spy- (bug #5192)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6563 65c4cc65-6c06-0410-ace0-fbb531ad65f3
1.2-netsec
Mark Spencer 20 years ago
parent 391d8b0994
commit f06a4016be

@ -514,7 +514,7 @@ datafiles: all
exit 1; \ exit 1; \
fi; \ fi; \
done done
for x in sounds/demo-* sounds/vm-* sounds/transfer* sounds/pbx-* sounds/ss-* sounds/beep* sounds/dir-* sounds/conf-* sounds/agent-* sounds/invalid* sounds/tt-* sounds/auth-* sounds/privacy-* sounds/queue-*; do \ for x in sounds/demo-* sounds/vm-* sounds/transfer* sounds/pbx-* sounds/ss-* sounds/beep* sounds/dir-* sounds/conf-* sounds/agent-* sounds/invalid* sounds/tt-* sounds/auth-* sounds/privacy-* sounds/queue-* sounds/spy-* sounds/priv-* sounds/screen-*; do \
if $(GREP) -q "^%`basename $$x`%" sounds.txt; then \ if $(GREP) -q "^%`basename $$x`%" sounds.txt; then \
install -m 644 $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds ; \ install -m 644 $$x $(DESTDIR)$(ASTVARLIBDIR)/sounds ; \
else \ else \

@ -514,7 +514,7 @@ static int chanspy_exec(struct ast_channel *chan, void *data)
struct localuser *u; struct localuser *u;
struct ast_channel *peer=NULL, *prev=NULL; struct ast_channel *peer=NULL, *prev=NULL;
char name[AST_NAME_STRLEN], char name[AST_NAME_STRLEN],
peer_name[AST_NAME_STRLEN], peer_name[AST_NAME_STRLEN + 5],
*args, *args,
*ptr = NULL, *ptr = NULL,
*options = NULL, *options = NULL,
@ -643,8 +643,8 @@ static int chanspy_exec(struct ast_channel *chan, void *data)
if (peer && (!bronly || ast_bridged_channel(peer)) && if (peer && (!bronly || ast_bridged_channel(peer)) &&
!ast_check_hangup(peer) && !ast_test_flag(peer, AST_FLAG_SPYING)) { !ast_check_hangup(peer) && !ast_test_flag(peer, AST_FLAG_SPYING)) {
int x = 0; int x = 0;
strncpy(peer_name, "spy-", 5);
strncpy(peer_name, peer->name, AST_NAME_STRLEN); strncpy(peer_name + strlen(peer_name), peer->name, AST_NAME_STRLEN);
ptr = strchr(peer_name, '/'); ptr = strchr(peer_name, '/');
*ptr = '\0'; *ptr = '\0';
ptr++; ptr++;

@ -710,18 +710,18 @@
%conf-onlyone.gsm%There is currently only one other participant in the conference. %conf-onlyone.gsm%There is currently only one other participant in the conference.
%agent.gsm%Agent %spy-agent.gsm%Agent
%h323.gsm%H.323 %spy-h323.gsm%H.323
%iax.gsm%IAX %spy-iax.gsm%IAX
%iax2.gsm%IAX (note: does not say "2") %spy-iax2.gsm%IAX (note: does not say "2")
%mgcp.gsm%MGCP %spy-mgcp.gsm%MGCP
%sip.gsm%SIP %spy-sip.gsm%SIP
%skinny.gsm%Skinny %spy-skinny.gsm%Skinny
%zap.gsm%Zap %spy-zap.gsm%Zap

Loading…
Cancel
Save