don't actually read the main `data' chunks; only refer to them by location.

allows support for huge wav files (eg, cdda.wav)
This commit is contained in:
Bill Currie 2003-04-10 21:34:51 +00:00
parent 8c13014ad9
commit c58dac3ccf

View file

@ -312,6 +312,20 @@ riff_read (QFile *f)
chunk = &list->ck;
}
break;
case CASE ('d','a','t','a'):
{
data_t *data = malloc (sizeof (data_t));
int c;
data->ck = ck;
data->data = malloc (sizeof (int));
*((int *)data->data) = Qtell (f);
Qseek (f, ck.len, SEEK_CUR);
if ((c = Qgetc (f)) && c != -1)
Qungetc (f, c);
chunk = &data->ck;
}
break;
default:
{
data_t *data = malloc (sizeof (data_t));