[xiph-commits] r3023 - liboggplay/trunk/src/liboggplay

shans at svn.annodex.net shans at svn.annodex.net
Thu Jun 21 06:42:32 PDT 2007


Author: shans
Date: 2007-06-21 06:42:32 -0700 (Thu, 21 Jun 2007)
New Revision: 3023

Modified:
   liboggplay/trunk/src/liboggplay/oggplay_data.c
Log:
Fixed valgrinds complaints, but a segfault still exists.



Modified: liboggplay/trunk/src/liboggplay/oggplay_data.c
===================================================================
--- liboggplay/trunk/src/liboggplay/oggplay_data.c	2007-06-21 13:03:07 UTC (rev 3022)
+++ liboggplay/trunk/src/liboggplay/oggplay_data.c	2007-06-21 13:42:32 UTC (rev 3023)
@@ -117,8 +117,8 @@
    * the untimed_data_list for later timestamping.
    */
   
-  OggPlayDataHeader *next_in_list;
-  
+  ogg_int64_t samples_in_next_in_list;
+ 
   //_print_list("before", decode->data_list);
   //_print_list("untimed before", decode->untimed_data_list);
   
@@ -132,17 +132,17 @@
      * First store any old data.
      */
     ogg_int64_t presentation_time         = data->presentation_time;
-    next_in_list                          = data;
+    samples_in_next_in_list               = data->samples_in_record;
+    
 
     while (decode->untimed_data_list != NULL) {
       OggPlayDataHeader *untimed = decode->untimed_data_list;
 
       presentation_time -= 
-                next_in_list->samples_in_record * decode->granuleperiod;
+                samples_in_next_in_list * decode->granuleperiod;
       untimed->presentation_time = presentation_time; 
-              
       decode->untimed_data_list = untimed->next;
-      next_in_list = untimed;
+      samples_in_next_in_list = untimed->samples_in_record;
      
       if (untimed->presentation_time >= decode->player->presentation_time) {
         oggplay_data_add_to_list_front(decode, untimed);



More information about the commits mailing list