mirror of
https://github.com/asterisk/asterisk.git
synced 2025-09-04 20:04:50 +00:00
Move static buffers to outside for loops in app_chanspy.
Similar to seanbright's commit 191422, this moves some static buffers to be defined outside of for loops since it is undefined if memory will be re-used or if the stack will grow with each iteration of the loop. git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@191628 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -508,6 +508,8 @@ static int common_exec(struct ast_channel *chan, const struct ast_flags *flags,
|
||||
char nameprefix[AST_NAME_STRLEN];
|
||||
char peer_name[AST_NAME_STRLEN + 5];
|
||||
signed char zero_volume = 0;
|
||||
char *groups[25];
|
||||
char dup_group[512];
|
||||
int waitms;
|
||||
int res;
|
||||
char *ptr;
|
||||
@@ -557,9 +559,7 @@ static int common_exec(struct ast_channel *chan, const struct ast_flags *flags,
|
||||
next_channel(chan, prev, spec, exten, context, &chanspy_ds), next_chanspy_ds = NULL) {
|
||||
const char *group;
|
||||
int igrp = !mygroup;
|
||||
char *groups[25];
|
||||
int num_groups = 0;
|
||||
char dup_group[512];
|
||||
int x;
|
||||
char *s;
|
||||
|
||||
|
Reference in New Issue
Block a user