Commit 375de459 authored by Austin Burrow's avatar Austin Burrow Committed by Konstantin Pavlov

Fixed the directory duplication bug in UPnP SD Client module and cleaned code.

Signed-off-by: default avatarKonstantin Pavlov <thresh@videolan.org>
parent 1e3e7a85
This diff is collapsed.
...@@ -40,12 +40,12 @@ class MediaServer ...@@ -40,12 +40,12 @@ class MediaServer
{ {
public: public:
static void parseDeviceDescription( IXML_Document* doc, static void parseDeviceDescription( IXML_Document* p_doc,
const char* location, const char* psz_location,
services_discovery_t* p_sd ); services_discovery_t* p_sd );
MediaServer( const char* UDN, MediaServer( const char* psz_udn,
const char* friendlyName, const char* psz_friendly_name,
services_discovery_t* p_sd ); services_discovery_t* p_sd );
~MediaServer(); ~MediaServer();
...@@ -53,10 +53,10 @@ public: ...@@ -53,10 +53,10 @@ public:
const char* getUDN() const; const char* getUDN() const;
const char* getFriendlyName() const; const char* getFriendlyName() const;
void setContentDirectoryEventURL( const char* url ); void setContentDirectoryEventURL( const char* psz_url );
const char* getContentDirectoryEventURL() const; const char* getContentDirectoryEventURL() const;
void setContentDirectoryControlURL( const char* url ); void setContentDirectoryControlURL( const char* psz_url );
const char* getContentDirectoryControlURL() const; const char* getContentDirectoryControlURL() const;
void subscribeToContentDirectory(); void subscribeToContentDirectory();
...@@ -64,29 +64,29 @@ public: ...@@ -64,29 +64,29 @@ public:
void setInputItem( input_item_t* p_input_item ); void setInputItem( input_item_t* p_input_item );
bool compareSID( const char* sid ); bool compareSID( const char* psz_sid );
private: private:
bool _fetchContents( Container* parent ); bool _fetchContents( Container* p_parent );
void _buildPlaylist( Container* container, input_item_node_t * ); void _buildPlaylist( Container* p_container, input_item_node_t *p_item_node );
IXML_Document* _browseAction( const char*, const char*, IXML_Document* _browseAction( const char*, const char*,
const char*, const char*, const char*, const char* ); const char*, const char*, const char*, const char* );
services_discovery_t* _p_sd; services_discovery_t* _p_sd;
Container* _contents; Container* _p_contents;
input_item_t* _inputItem; input_item_t* _p_input_item;
std::string _UDN; std::string _UDN;
std::string _friendlyName; std::string _friendly_name;
std::string _contentDirectoryEventURL; std::string _content_directory_event_url;
std::string _contentDirectoryControlURL; std::string _content_directory_control_url;
int _subscriptionTimeOut; int _i_subscription_timeout;
Upnp_SID _subscriptionID; Upnp_SID _subscription_id;
}; };
...@@ -97,11 +97,11 @@ public: ...@@ -97,11 +97,11 @@ public:
MediaServerList( services_discovery_t* p_sd ); MediaServerList( services_discovery_t* p_sd );
~MediaServerList(); ~MediaServerList();
bool addServer( MediaServer* s ); bool addServer( MediaServer* p_server );
void removeServer( const char* UDN ); void removeServer( const char* psz_udn );
MediaServer* getServer( const char* UDN ); MediaServer* getServer( const char* psz_udn );
MediaServer* getServerBySID( const char* ); MediaServer* getServerBySID( const char* psz_sid );
private: private:
...@@ -130,7 +130,7 @@ public: ...@@ -130,7 +130,7 @@ public:
private: private:
input_item_t* _inputItem; input_item_t* _p_input_item;
Container* _parent; Container* _parent;
std::string _objectID; std::string _objectID;
...@@ -164,7 +164,7 @@ public: ...@@ -164,7 +164,7 @@ public:
private: private:
input_item_t* _inputItem; input_item_t* _p_input_item;
Container* _parent; Container* _parent;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment