]> git.ipfire.org Git - thirdparty/asterisk.git/commit
file: Ensure nativeformats remains valid for lifetime of use. 64/2764/2
authorJoshua Colp <jcolp@digium.com>
Thu, 5 May 2016 10:07:50 +0000 (07:07 -0300)
committerJoshua Colp <jcolp@digium.com>
Thu, 5 May 2016 16:02:56 +0000 (11:02 -0500)
commit4e7791d4835030890cc4e6335a8c89eb67e3cf5d
tree86d94a1bd2e94fbcad91792d5e043cd7d082c434
parent601602f44b72c20a265d39f217eeda3d335712e9
file: Ensure nativeformats remains valid for lifetime of use.

It is possible for the nativeformats of a channel to change
throughout its lifetime. As a result a user of it needs to either
ensure the channel is locked when accessing the formats or keep
a reference to the nativeformats themselves.

This change fixes the file playback support so it keeps a
reference to the nativeformats when accessing things.

ASTERISK-25998 #close

Change-Id: Ie45b65475e1481ddf05b874ee48f63e39fff8915
main/file.c