aboutsummaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2008-12-16 14:31:02 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2008-12-16 14:31:02 +0000
commit3ad06122c6da3da61261a4e7c902fab8f9803459 (patch)
tree09b94eaea4986bab9cc9ea697592d5da8d80060f /res
parent33d2c8c8150f92dea0e4e77415d1e40ad83bf914 (diff)
Merged revisions 164605 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r164605 | russell | 2008-12-16 08:28:10 -0600 (Tue, 16 Dec 2008) | 5 lines Don't try to change working directory if a directory was not configured. (closes issue #14089) Reported by: caspy ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@164606 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'res')
-rw-r--r--res/res_musiconhold.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/res/res_musiconhold.c b/res/res_musiconhold.c
index bebc08a4e..091a6a5b8 100644
--- a/res/res_musiconhold.c
+++ b/res/res_musiconhold.c
@@ -512,7 +512,7 @@ static int spawn_mp3(struct mohclass *class)
ast_close_fds_above_n(STDERR_FILENO);
/* Child */
- if (chdir(class->dir) < 0) {
+ if (strcasecmp(class->dir, "nodir") && chdir(class->dir) < 0) {
ast_log(LOG_WARNING, "chdir() failed: %s\n", strerror(errno));
_exit(1);
}