[vlc-commits] demux: adaptative: remove unused source reference

Francois Cartegnie git at videolan.org
Wed Dec 2 15:27:55 CET 2015


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Wed Dec  2 14:48:58 2015 +0100| [d5bdee3c1bedd12c388d365f19ddfecef0d972cd] | committer: Francois Cartegnie

demux: adaptative: remove unused source reference

> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=d5bdee3c1bedd12c388d365f19ddfecef0d972cd
---

 modules/demux/adaptative/http/Chunk.cpp |    9 +--------
 modules/demux/adaptative/http/Chunk.h   |    2 --
 2 files changed, 1 insertion(+), 10 deletions(-)

diff --git a/modules/demux/adaptative/http/Chunk.cpp b/modules/demux/adaptative/http/Chunk.cpp
index 63ad8ab..1acf8b0 100644
--- a/modules/demux/adaptative/http/Chunk.cpp
+++ b/modules/demux/adaptative/http/Chunk.cpp
@@ -38,7 +38,6 @@ using namespace adaptative::http;
 
 AbstractChunkSource::AbstractChunkSource()
 {
-    parentChunk = NULL;
     contentLength = 0;
 }
 
@@ -47,11 +46,6 @@ AbstractChunkSource::~AbstractChunkSource()
 
 }
 
-void AbstractChunkSource::setParentChunk(AbstractChunk *parent)
-{
-    parentChunk = parent;
-}
-
 void AbstractChunkSource::setBytesRange(const BytesRange &range)
 {
     bytesRange = range;
@@ -68,7 +62,6 @@ AbstractChunk::AbstractChunk(AbstractChunkSource *source_)
 {
     bytesRead = 0;
     source = source_;
-    source->setParentChunk(this);
 }
 
 AbstractChunk::~AbstractChunk()
@@ -228,7 +221,7 @@ bool HTTPChunkSource::prepare()
     if(prepared)
         return true;
 
-    if(!connManager || !parentChunk)
+    if(!connManager)
         return false;
 
     if(!connection)
diff --git a/modules/demux/adaptative/http/Chunk.h b/modules/demux/adaptative/http/Chunk.h
index f811a0e..0e632b7 100644
--- a/modules/demux/adaptative/http/Chunk.h
+++ b/modules/demux/adaptative/http/Chunk.h
@@ -48,12 +48,10 @@ namespace adaptative
                 virtual block_t *   readBlock       () = 0;
                 virtual block_t *   read            (size_t) = 0;
                 virtual bool        hasMoreData     () const = 0;
-                void                setParentChunk  (AbstractChunk *);
                 void                setBytesRange   (const BytesRange &);
                 const BytesRange &  getBytesRange   () const;
 
             protected:
-                AbstractChunk      *parentChunk;
                 size_t              contentLength;
                 BytesRange          bytesRange;
         };



More information about the vlc-commits mailing list