aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorqwell <qwell@f38db490-d61c-443f-a65b-d21fe96a405b>2011-02-01 17:02:09 +0000
committerqwell <qwell@f38db490-d61c-443f-a65b-d21fe96a405b>2011-02-01 17:02:09 +0000
commitdd5e14d165f1aace61defca11b33cc12c024a8b8 (patch)
treeb4c8a52abdd064afc069d634766392913b64dcfc
parentfeff2e2395771695d50ad5d6189302c4045e2683 (diff)
Merged revisions 305471 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r305471 | qwell | 2011-02-01 11:00:55 -0600 (Tue, 01 Feb 2011) | 9 lines Close file descriptor for timing source when a MOH class gets destroyed. (closes issue #18457) Reported by: mcallist Patches: 18457-closetimer.diff uploaded by qwell (license 4) 18457-closetimer_trunk.diff uploaded by qwell (license 4) Tested by: qwell, loloski ........ git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@305472 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r--res/res_musiconhold.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/res/res_musiconhold.c b/res/res_musiconhold.c
index ef15905d8..3a1484f1d 100644
--- a/res/res_musiconhold.c
+++ b/res/res_musiconhold.c
@@ -1559,6 +1559,11 @@ static void moh_class_destructor(void *obj)
free(member);
}
+ if (class->pseudofd > -1) {
+ close(class->pseudofd);
+ class->pseudofd = -1;
+ }
+
if (class->filearray) {
int i;
for (i = 0; i < class->total_files; i++) {