[MPlayer-cvslog] r29627 - trunk/libmpdemux/demux_rtp.cpp

reimar subversion at mplayerhq.hu
Wed Sep 2 13:07:02 CEST 2009


Author: reimar
Date: Wed Sep  2 13:07:02 2009
New Revision: 29627

Log:
free(), delete and delete[] are all different and can't just be used at random,
so change code to use the one appropriate for the allocation used.

Modified:
   trunk/libmpdemux/demux_rtp.cpp

Modified: trunk/libmpdemux/demux_rtp.cpp
==============================================================================
--- trunk/libmpdemux/demux_rtp.cpp	Wed Sep  2 12:55:36 2009	(r29626)
+++ trunk/libmpdemux/demux_rtp.cpp	Wed Sep  2 13:07:02 2009	(r29627)
@@ -389,7 +389,7 @@ extern "C" void demux_close_rtp(demuxer_
   Medium::close(rtpState->sipClient);
   delete rtpState->audioBufferQueue;
   delete rtpState->videoBufferQueue;
-  delete rtpState->sdpDescription;
+  delete[] rtpState->sdpDescription;
   delete rtpState;
 #ifdef CONFIG_LIBAVCODEC
   av_freep(&avcctx);
@@ -631,7 +631,7 @@ ReadBufferQueue::ReadBufferQueue(MediaSu
 }
 
 ReadBufferQueue::~ReadBufferQueue() {
-  delete fTag;
+  free((void *)fTag);
 
   // Free any pending buffers (that never got delivered):
   demux_packet_t* dp = pendingDPHead;


More information about the MPlayer-cvslog mailing list