aboutsummaryrefslogtreecommitdiffstats
path: root/res
diff options
context:
space:
mode:
authorjpeeler <jpeeler@f38db490-d61c-443f-a65b-d21fe96a405b>2010-03-05 01:05:46 +0000
committerjpeeler <jpeeler@f38db490-d61c-443f-a65b-d21fe96a405b>2010-03-05 01:05:46 +0000
commit7cb8dcb72b32714a2600f08a55e5e2f65449a22d (patch)
tree3d54b0ff3f85cc1326d1235b25e79e7acc9d1e4d /res
parent4f6972573b9e0788a7a9b8205772281c2077038b (diff)
Merged revisions 250786 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r250786 | jpeeler | 2010-03-04 19:02:58 -0600 (Thu, 04 Mar 2010) | 9 lines Fix not being able to specify a URL in MOH class directory. Don't attempt to chdir on a URL! (closes issue #16875) Reported by: raarts Patches: moh-http.patch uploaded by raarts (license 937) ........ git-svn-id: http://svn.digium.com/svn/asterisk/trunk@250787 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 82e053478..676b0184a 100644
--- a/res/res_musiconhold.c
+++ b/res/res_musiconhold.c
@@ -560,7 +560,7 @@ static int spawn_mp3(struct mohclass *class)
ast_close_fds_above_n(STDERR_FILENO);
/* Child */
- if (strcasecmp(class->dir, "nodir") && chdir(class->dir) < 0) {
+ if (strncasecmp(class->dir, "http://", 7) && strcasecmp(class->dir, "nodir") && chdir(class->dir) < 0) {
ast_log(LOG_WARNING, "chdir() failed: %s\n", strerror(errno));
_exit(1);
}