mirror of
https://github.com/crskycode/GARbro.git
synced 2025-01-12 04:49:32 +08:00
(EogAudio.TryOpen): don't dispose of intermediate stream.
This commit is contained in:
parent
f47432fc09
commit
a47817101e
@ -39,15 +39,8 @@ namespace GameRes.Formats.Crowd
|
|||||||
public override SoundInput TryOpen (Stream file)
|
public override SoundInput TryOpen (Stream file)
|
||||||
{
|
{
|
||||||
var ogg = new StreamRegion (file, 8);
|
var ogg = new StreamRegion (file, 8);
|
||||||
try
|
|
||||||
{
|
|
||||||
return new OggInput (ogg);
|
return new OggInput (ogg);
|
||||||
}
|
// in case of exception ogg stream is left undisposed
|
||||||
catch
|
|
||||||
{
|
|
||||||
ogg.Dispose();
|
|
||||||
throw;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
public override void Write (SoundInput source, Stream output)
|
public override void Write (SoundInput source, Stream output)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user