The SVDRP port now accepts multiple concurrent connections

This commit is contained in:
Klaus Schmidinger
2015-04-29 13:10:06 +02:00
parent b6af7a9cf9
commit 2b9e988dd5
6 changed files with 221 additions and 147 deletions

View File

@@ -4,7 +4,7 @@
* See the main source file 'vdr.c' for copyright information and
* how to reach the author.
*
* $Id: interface.c 3.1 2015/01/11 13:37:47 kls Exp $
* $Id: interface.c 4.1 2015/04/28 11:16:06 kls Exp $
*/
#include "interface.h"
@@ -19,27 +19,19 @@
cInterface *Interface = NULL;
cInterface::cInterface(int SVDRPport)
cInterface::cInterface(void)
{
interrupted = false;
SVDRP = NULL;
if (SVDRPport)
SVDRP = new cSVDRP(SVDRPport);
}
cInterface::~cInterface()
{
delete SVDRP;
}
eKeys cInterface::GetKey(bool Wait)
{
if (!cRemote::HasKeys())
Skins.Flush();
if (SVDRP) {
if (SVDRP->Process())
Wait = false;
}
if (!cRemote::IsLearning())
return cRemote::Get(Wait ? 1000 : 10);
else