aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2007-10-01 15:23:19 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2007-10-01 15:23:19 +0000
commitdac373f5395aca9a9f3f75b089e415ec6f0a51f4 (patch)
tree5c5be0ea22d3b81ee644e5f620052a4f25f14e02 /apps
parentb9f6c27beb072516a1bec8b7261b05ac902c2093 (diff)
Corydon posted this janitor project to the bug tracker and mvanbaak provided
a patch for it. It replaces a bunch of simple calls to snprintf with ast_copy_string (closes issue #10843) Reported by: Corydon76 Patches: 2007092900_10843.diff uploaded by mvanbaak (license 7) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@84173 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps')
-rw-r--r--apps/app_meetme.c2
-rw-r--r--apps/app_minivm.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/apps/app_meetme.c b/apps/app_meetme.c
index 8505e7131..2ec526a13 100644
--- a/apps/app_meetme.c
+++ b/apps/app_meetme.c
@@ -1477,7 +1477,7 @@ static int conf_run(struct ast_channel *chan, struct ast_conference *conf, int c
}
conf->recordingformat = pbx_builtin_getvar_helper(chan, "MEETME_RECORDINGFORMAT");
if (!conf->recordingformat) {
- snprintf(recordingtmp, sizeof(recordingtmp), "wav");
+ ast_copy_string(recordingtmp, "wav", sizeof(recordingtmp));
conf->recordingformat = ast_strdupa(recordingtmp);
}
ast_verb(4, "Starting recording of MeetMe Conference %s into file %s.%s.\n",
diff --git a/apps/app_minivm.c b/apps/app_minivm.c
index e63de2668..2dff27031 100644
--- a/apps/app_minivm.c
+++ b/apps/app_minivm.c
@@ -934,7 +934,7 @@ static int sendmail(struct minivm_template *template, struct minivm_account *vmu
char tmpcmd[PATH_MAX];
int tmpfd;
- snprintf(newtmp, sizeof(newtmp), "/tmp/XXXXXX");
+ ast_copy_string(newtmp, "/tmp/XXXXXX", sizeof(newtmp));
ast_debug(3, "newtmp: %s\n", newtmp);
tmpfd = mkstemp(newtmp);
snprintf(tmpcmd, sizeof(tmpcmd), "sox -v %.4f %s.%s %s.%s", vmu->volgain, filename, format, newtmp, format);