[FFmpeg-cvslog] r17476 - trunk/ffplay.c
aurel
subversion
Sat Feb 21 17:01:53 CET 2009
Author: aurel
Date: Sat Feb 21 17:01:52 2009
New Revision: 17476
Log:
Take account of struct size in total packet queue size tracking.
fix issue806
Modified:
trunk/ffplay.c
Modified: trunk/ffplay.c
==============================================================================
--- trunk/ffplay.c Sat Feb 21 16:32:56 2009 (r17475)
+++ trunk/ffplay.c Sat Feb 21 17:01:52 2009 (r17476)
@@ -282,7 +282,7 @@ static int packet_queue_put(PacketQueue
q->last_pkt->next = pkt1;
q->last_pkt = pkt1;
q->nb_packets++;
- q->size += pkt1->pkt.size;
+ q->size += pkt1->pkt.size + sizeof(*pkt1);
/* XXX: should duplicate packet data in DV case */
SDL_CondSignal(q->cond);
@@ -321,7 +321,7 @@ static int packet_queue_get(PacketQueue
if (!q->first_pkt)
q->last_pkt = NULL;
q->nb_packets--;
- q->size -= pkt1->pkt.size;
+ q->size -= pkt1->pkt.size + sizeof(*pkt1);
*pkt = pkt1->pkt;
av_free(pkt1);
ret = 1;
More information about the ffmpeg-cvslog
mailing list