[vlc-commits] demux: adaptive: add a connmanager to shared resources

Francois Cartegnie git at videolan.org
Wed Oct 16 20:21:09 CEST 2019


vlc | branch: master | Francois Cartegnie <fcvlcdev at free.fr> | Wed Oct 16 17:16:15 2019 +0200| [3d3d1219366c0adc7e678c26fc8ae94f07806214] | committer: Francois Cartegnie

demux: adaptive: add a connmanager to shared resources

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

 modules/demux/adaptive/SharedResources.cpp | 8 ++++++++
 modules/demux/adaptive/SharedResources.hpp | 3 +++
 2 files changed, 11 insertions(+)

diff --git a/modules/demux/adaptive/SharedResources.cpp b/modules/demux/adaptive/SharedResources.cpp
index 0b6e323151..f09c088569 100644
--- a/modules/demux/adaptive/SharedResources.cpp
+++ b/modules/demux/adaptive/SharedResources.cpp
@@ -23,6 +23,7 @@
 
 #include "SharedResources.hpp"
 #include "http/AuthStorage.hpp"
+#include "http/HTTPConnectionManager.h"
 #include "encryption/Keyring.hpp"
 
 #include <vlc_common.h>
@@ -33,10 +34,12 @@ SharedResources::SharedResources(vlc_object_t *obj)
 {
     authStorage = new AuthStorage(obj);
     encryptionKeyring = new Keyring(obj);
+    connManager = new HTTPConnectionManager(obj, authStorage);
 }
 
 SharedResources::~SharedResources()
 {
+    delete connManager;
     delete encryptionKeyring;
     delete authStorage;
 }
@@ -50,3 +53,8 @@ Keyring * SharedResources::getKeyring()
 {
     return encryptionKeyring;
 }
+
+AbstractConnectionManager * SharedResources::getConnManager()
+{
+    return connManager;
+}
diff --git a/modules/demux/adaptive/SharedResources.hpp b/modules/demux/adaptive/SharedResources.hpp
index 2a63578e3b..5eff6eec06 100644
--- a/modules/demux/adaptive/SharedResources.hpp
+++ b/modules/demux/adaptive/SharedResources.hpp
@@ -27,6 +27,7 @@ namespace adaptive
     namespace http
     {
         class AuthStorage;
+        class AbstractConnectionManager;
     }
 
     namespace encryption
@@ -44,10 +45,12 @@ namespace adaptive
             ~SharedResources();
             AuthStorage *getAuthStorage();
             Keyring     *getKeyring();
+            AbstractConnectionManager *getConnManager();
 
         private:
             AuthStorage *authStorage;
             Keyring *encryptionKeyring;
+            AbstractConnectionManager *connManager;
     };
 }
 



More information about the vlc-commits mailing list