Index: apps/app_macro.c =================================================================== RCS file: /usr/cvsroot/asterisk/apps/app_macro.c,v retrieving revision 1.14 diff -u -p -r1.14 app_macro.c --- apps/app_macro.c 22 Jun 2004 19:32:52 -0000 1.14 +++ apps/app_macro.c 13 Jul 2004 20:04:41 -0000 @@ -122,8 +122,9 @@ static int macro_exec(struct ast_channel pbx_builtin_setvar_helper(chan, "MACRO_OFFSET", NULL); /* Setup environment for new run */ - strcpy(chan->exten, "s"); - strncpy(chan->context, fullmacro, sizeof(chan->context)); + chan->exten[0] = 's'; + chan->exten[1] = '\0'; + strncpy(chan->context, fullmacro, sizeof(chan->context) - 1); chan->priority = 1; while((cur = strsep(&rest, "|")) && (argc < MAX_ARGS)) { @@ -193,8 +194,8 @@ out: pbx_builtin_setvar_helper(chan, "MACRO_PRIORITY", save_macro_priority); if (save_macro_priority) free(save_macro_priority); if (setmacrocontext) { - strcpy(chan->macrocontext, ""); - strcpy(chan->macroexten, ""); + chan->macrocontext[0] = '\0'; + chan->macroexten[0] = '\0'; chan->macropriority = 0; }