]> git.sesse.net Git - vlc/commitdiff
dash: DOMparser: Replacing an init method by an init list.
authorHugo Beauzée-Luyssen <beauze.h@gmail.com>
Fri, 25 Nov 2011 13:51:46 +0000 (14:51 +0100)
committerJean-Baptiste Kempf <jb@videolan.org>
Sat, 26 Nov 2011 11:34:31 +0000 (12:34 +0100)
Signed-off-by: Jean-Baptiste Kempf <jb@videolan.org>
modules/stream_filter/dash/xml/DOMParser.cpp
modules/stream_filter/dash/xml/DOMParser.h

index 63ce99519bd90e9b7f93a06d0acd9c1890d6fcc8..16161670e9849cec1e6d7913e349dbe58784e792 100644 (file)
@@ -31,11 +31,14 @@ using namespace dash::xml;
 using namespace dash::http;
 using namespace dash::mpd;
 
-DOMParser::DOMParser    (stream_t *stream)
+DOMParser::DOMParser    (stream_t *stream) :
+    root( NULL ),
+    stream( stream ),
+    vlc_xml( NULL ),
+    vlc_reader( NULL )
 {
-    this->stream = stream;
-    this->init();
 }
+
 DOMParser::~DOMParser   ()
 {
     if(this->vlc_reader)
@@ -123,11 +126,7 @@ void    DOMParser::print                    (Node *node, int offset)
         this->print(node->getSubNodes().at(i), offset);
     }
 }
-void    DOMParser::init                     ()
-{
-    this->root          = NULL;
-    this->vlc_reader    = NULL;
-}
+
 void    DOMParser::print                    ()
 {
     this->print(this->root, 0);
index 2042a5fe1561b910f5583b8129d60976f6b9967b..611a783ba912e69d9c0350d592910c1ddd68396b 100644 (file)
@@ -64,7 +64,6 @@ namespace dash
                 xml_t               *vlc_xml;
                 xml_reader_t        *vlc_reader;
 
-                void    init                    ();
                 Node*   processNode             ();
                 void    addAttributesToNode     (Node *node);
                 void    print                   (Node *node, int offset);