mirror of
https://github.com/vgmstream/vgmstream.git
synced 2024-12-01 01:27:20 +01:00
clean up a few uninitialized things
git-svn-id: https://vgmstream.svn.sourceforge.net/svnroot/vgmstream@721 51a99a44-fe44-0410-b1ba-c3e57ba2b86b
This commit is contained in:
parent
205a195fc8
commit
32cac29937
@ -7,12 +7,12 @@ VGMSTREAM * init_vgmstream_apple_caff(STREAMFILE *streamFile) {
|
||||
VGMSTREAM * vgmstream = NULL;
|
||||
char filename[260];
|
||||
|
||||
off_t start_offset;
|
||||
off_t data_size;
|
||||
off_t sample_count;
|
||||
off_t interleave;
|
||||
int sample_rate,unused_frames;
|
||||
int channel_count;
|
||||
off_t start_offset = 0;
|
||||
off_t data_size = 0;
|
||||
off_t sample_count = 0;
|
||||
off_t interleave = 0;
|
||||
int sample_rate = -1, unused_frames = 0;
|
||||
int channel_count = 0;
|
||||
|
||||
off_t file_length;
|
||||
off_t chunk_offset = 8;
|
||||
@ -120,6 +120,8 @@ VGMSTREAM * init_vgmstream_apple_caff(STREAMFILE *streamFile) {
|
||||
}
|
||||
|
||||
if (!found_pakt || !found_desc || !found_data) goto fail;
|
||||
if (start_offset == 0 || data_size == 0 || sample_count == 0 ||
|
||||
sample_rate == -1 || channel_count == 0) goto fail;
|
||||
|
||||
/* ima4-specific */
|
||||
/* check for full packets */
|
||||
|
@ -11,8 +11,7 @@ VGMSTREAM * init_vgmstream_waa_wac_wad_wam(STREAMFILE *streamFile) {
|
||||
int channel_count;
|
||||
int coef1_start;
|
||||
int coef2_start;
|
||||
int i;
|
||||
int second_channel_start;
|
||||
int second_channel_start = -1;
|
||||
|
||||
// Check file extensions
|
||||
streamFile->get_name(streamFile,filename,sizeof(filename));
|
||||
@ -119,6 +118,7 @@ VGMSTREAM * init_vgmstream_waa_wac_wad_wam(STREAMFILE *streamFile) {
|
||||
} else {
|
||||
vgmstream->ch[0].channel_start_offset=start_offset;
|
||||
if (channel_count == 2) {
|
||||
if (second_channel_start == -1) goto fail;
|
||||
vgmstream->ch[1].channel_start_offset=second_channel_start;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user