summaryrefslogtreecommitdiff
path: root/upnp.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'upnp.cpp')
-rw-r--r--upnp.cpp11
1 files changed, 11 insertions, 0 deletions
diff --git a/upnp.cpp b/upnp.cpp
index f634b5e..bf585d7 100644
--- a/upnp.cpp
+++ b/upnp.cpp
@@ -10,10 +10,13 @@
#include <getopt.h>
#include "upnp.h"
#include "include/setup.h"
+#include "include/media/requestCounter.h"
using namespace std;
using namespace upnp;
+int request_counter_t::OPEN_REQUESTS = 0;
+
cPluginUpnp::cPluginUpnp(void)
{
mMediaServer = cMediaServer::GetInstance();
@@ -78,6 +81,14 @@ void cPluginUpnp::Stop(void)
mMediaServer->Stop();
}
+cString cPluginUpnp::Active(void)
+{
+ if(request_counter_t::OPEN_REQUESTS > 0){
+ return cString::sprintf(tr("There are %d requests active."), request_counter_t::OPEN_REQUESTS);
+ }
+ return NULL;
+}
+
void cPluginUpnp::Housekeeping(void)
{
// Perform any cleanup or other regular tasks.