Audio: Fix stream not being unlocked on exception
This commit is contained in:
parent
99866fb84c
commit
01529c5741
|
@ -1273,7 +1273,19 @@ struct AudioStream
|
|||
stream.close();
|
||||
case ALStream::Closed :
|
||||
if (diffFile)
|
||||
stream.open(filename);
|
||||
{
|
||||
try
|
||||
{
|
||||
/* This will throw on errors while
|
||||
* opening the data source */
|
||||
stream.open(filename);
|
||||
}
|
||||
catch (const Exception &e)
|
||||
{
|
||||
unlockStream();
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue