Fixed memory leak
This was SVN commit r1598.
This commit is contained in:
parent
e72addb945
commit
7efc7a7903
@ -896,6 +896,9 @@ static void SndData_dtor(SndData* sd)
|
||||
stream_close(&sd->s);
|
||||
else
|
||||
al_buf_free(sd->al_buf);
|
||||
#ifdef OGG_HACK
|
||||
if(sd->o) ogg_release(sd->o);
|
||||
#endif
|
||||
}
|
||||
|
||||
|
||||
@ -990,6 +993,10 @@ if(file_type == FT_OGG)
|
||||
al_data = &data[0];
|
||||
al_size = (ALsizei)datasize;
|
||||
}
|
||||
else
|
||||
{
|
||||
sd->o = NULL;
|
||||
}
|
||||
#endif
|
||||
|
||||
sd->al_buf = al_buf_alloc(al_data, al_size, sd->al_fmt, sd->al_freq);
|
||||
|
Loading…
Reference in New Issue
Block a user