]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
Set file descriptors to -1 on creation, so that we don't see weirdness later.
authorJason Parker <jparker@digium.com>
Mon, 31 Jan 2011 20:56:25 +0000 (20:56 +0000)
committerJason Parker <jparker@digium.com>
Mon, 31 Jan 2011 20:56:25 +0000 (20:56 +0000)
git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@305129 65c4cc65-6c06-0410-ace0-fbb531ad65f3

res/res_musiconhold.c

index f67fa5a1ccb1ae24a28516cf8e9a8f29eb36271e..fae51b9a2f5bdbf82f3ae1bd13367ebd0670ac8f 100644 (file)
@@ -1159,6 +1159,8 @@ static struct mohclass *moh_class_malloc(void)
 
        if ((class = ao2_alloc(sizeof(*class), moh_class_destructor))) {
                class->format = AST_FORMAT_SLINEAR;
+               class->srcfd = -1;
+               class->pseudofd = -1;
        }
 
        return class;