From: Russell Bryant Date: Fri, 5 Nov 2004 02:45:59 +0000 (+0000) Subject: fix non standard characters (bug 2778) X-Git-Tag: 1.0.11.1~400 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7352e07e126aeb65cbfcf88a1898c215448e0300;p=thirdparty%2Fasterisk.git fix non standard characters (bug 2778) git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/v1-0@4162 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/CHANGES b/CHANGES index d65e2ecfd7..3f5201de17 100755 --- a/CHANGES +++ b/CHANGES @@ -2,6 +2,8 @@ -- fix numbers for portuguese -- chan_sip -- fix to prevent seg fault when attempting a transfer + -- chan_h323 + -- fix compilation problem Asterisk 1.0.2 -- Major bugfix release Asterisk 1.0.1 diff --git a/res/res_monitor.c b/res/res_monitor.c index 2a0b00fa4b..a3f1747ecc 100755 --- a/res/res_monitor.c +++ b/res/res_monitor.c @@ -103,7 +103,7 @@ int ast_monitor_start( struct ast_channel *chan, const char *format_spec, /* try creating the directory just in case it doesn't exist */ if (directory) { char *name = strdup(fname_base); - snprintf(tmp, sizeof(tmp), "mkdir -p %s",dirname(name)); + snprintf(tmp, sizeof(tmp), "mkdir -p \"%s\"",dirname(name)); free(name); system(tmp); } @@ -243,9 +243,9 @@ int ast_monitor_stop(struct ast_channel *chan, int need_lock) execute_args = ""; } - snprintf(tmp, sizeof(tmp), "%s %s/%s-in.%s %s/%s-out.%s %s/%s.%s %s &", execute, dir, name, format, dir, name, format, dir, name, format,execute_args); + snprintf(tmp, sizeof(tmp), "%s \"%s/%s-in.%s\" \"%s/%s-out.%s\" \"%s/%s.%s\" %s &", execute, dir, name, format, dir, name, format, dir, name, format,execute_args); if (delfiles) { - snprintf(tmp2,sizeof(tmp2), "( %s& rm -f %s/%s-* ) &",tmp, dir ,name); /* remove legs when done mixing */ + snprintf(tmp2,sizeof(tmp2), "( %s& rm -f \"%s\"/%s-* ) &",tmp, dir ,name); /* remove legs when done mixing */ strncpy(tmp, tmp2, sizeof(tmp) - 1); } ast_verbose("monitor executing %s\n",tmp);