From: Andre Noll Date: Sat, 5 Mar 2011 11:53:02 +0000 (+0100) Subject: Merge branch 't/vorbis_dummy_header' X-Git-Tag: v0.4.6~19 X-Git-Url: http://git.tue.mpg.de/?a=commitdiff_plain;h=1c8226eae0e976d940366cd10bd708d8e4d0bca5;p=paraslash.git Merge branch 't/vorbis_dummy_header' --- 1c8226eae0e976d940366cd10bd708d8e4d0bca5 diff --cc ogg_afh_common.c index 72fab7c1,ad5963eb..cb59d363 --- a/ogg_afh_common.c +++ b/ogg_afh_common.c @@@ -142,9 -145,12 +144,12 @@@ int ogg_get_file_info(char *map, size_ ret = process_ogg_packets(&oss, afhi, ci); if (ret < 0) goto out; + if (!afhi) + goto out; + afhi->header_len = oss.returned; oss.returned = 0; oss.fill = numbytes; - /* count ogg packages and get duration of the file */ + /* count ogg pages and get duration of the file */ for (i = 0; ogg_sync_pageseek(&oss, &op) > 0; i++) num_frames = ogg_page_granulepos(&op); PARA_INFO_LOG("%d pages, %llu frames\n", i, num_frames);