changeset 1184:5a743f6f836a libavformat

fix regression failure after adler simplification
author michael
date Thu, 20 Jul 2006 10:22:07 +0000
parents 5b04d98e11bb
children 13dc486b272b
files aviobuf.c nut.c
diffstat 2 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/aviobuf.c	Wed Jul 19 09:38:22 2006 +0000
+++ b/aviobuf.c	Thu Jul 20 10:22:07 2006 +0000
@@ -298,7 +298,7 @@
 void init_checksum(ByteIOContext *s, unsigned long (*update_checksum)(unsigned long c, const uint8_t *p, unsigned int len), unsigned long checksum){
     s->update_checksum= update_checksum;
     if(s->update_checksum){
-        s->checksum= s->update_checksum(checksum, NULL, 0);
+        s->checksum= checksum;
         s->checksum_ptr= s->buf_ptr;
     }
 }
--- a/nut.c	Wed Jul 19 09:38:22 2006 +0000
+++ b/nut.c	Thu Jul 20 10:22:07 2006 +0000
@@ -331,7 +331,7 @@
 
     size= get_v(bc);
 
-    init_checksum(bc, calculate_checksum ? av_adler32_update : NULL, 0);
+    init_checksum(bc, calculate_checksum ? av_adler32_update : NULL, 1);
 
     nut->packet_start[2] = start;
     nut->written_packet_size= size;
@@ -476,7 +476,7 @@
     put_v(bc, nut->written_packet_size); /* forward ptr */
 
     if(calculate_checksum)
-        init_checksum(bc, av_adler32_update, 0);
+        init_checksum(bc, av_adler32_update, 1);
 
     return 0;
 }