mirror of
https://git.code.sf.net/p/quake/quakeforge
synced 2024-11-23 12:52:46 +00:00
fix the file handle leak
This commit is contained in:
parent
efe9dd844f
commit
194c9aa097
2 changed files with 3 additions and 3 deletions
|
@ -526,8 +526,8 @@ SND_UpdateAmbientSounds (void)
|
|||
if (!ambient_sfx[ambient_channel]) {
|
||||
chan->sfx = 0;
|
||||
continue;
|
||||
}
|
||||
chan->sfx = ambient_sfx[ambient_channel]->open (ambient_sfx[ambient_channel]);
|
||||
} else if (!chan->sfx)
|
||||
chan->sfx = ambient_sfx[ambient_channel]->open (ambient_sfx[ambient_channel]);
|
||||
|
||||
vol = ambient_level->value * l->ambient_sound_level[ambient_channel];
|
||||
if (vol < 8)
|
||||
|
|
|
@ -263,7 +263,7 @@ vorbis_stream_open (sfx_t *_sfx)
|
|||
QFS_FOpenFile (stream->file, &file);
|
||||
if (!file)
|
||||
return 0;
|
||||
|
||||
puts (stream->file);
|
||||
sfx = calloc (1, sizeof (sfx_t));
|
||||
samples = shm->speed * 0.3;
|
||||
size = samples = (samples + 255) & ~255;
|
||||
|
|
Loading…
Reference in a new issue