Skip to content

Commit

Permalink
app_rpt.c: Fix issue 469 - truncated link list in RPT_LINK
Browse files Browse the repository at this point in the history
  • Loading branch information
mkmer committed Jan 27, 2025
1 parent e4dee90 commit ce000cc
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion apps/app_rpt.c
Original file line number Diff line number Diff line change
Expand Up @@ -1661,14 +1661,17 @@ static inline void init_text_frame(struct ast_frame *wf)

static void handle_link_data(struct rpt *myrpt, struct rpt_link *mylink, char *str)
{
char tmp[512], tmp1[512], cmd[300] = "", dest[300], src[30], c;
char tmp[MAXLINKLIST], tmp1[512], cmd[300] = "", dest[300], src[30], c;
int i, seq, res, ts, rest;
struct ast_frame wf;

init_text_frame(&wf);
wf.datalen = strlen(str) + 1;
wf.src = "handle_link_data";
/* put string in our buffer */
if (strlen(str) > sizeof(tmp)){
ast_log(LOG_WARNING,"Link text message data has exceeded tmp buffer size");
}
ast_copy_string(tmp, str, sizeof(tmp) - 1);

ast_debug(5, "Received text over link: '%s'\n", str);
Expand Down

0 comments on commit ce000cc

Please sign in to comment.