diff --git a/src/zapit/include/zapit/zapit.h b/src/zapit/include/zapit/zapit.h index d71ba5f73..eff7b205f 100644 --- a/src/zapit/include/zapit/zapit.h +++ b/src/zapit/include/zapit/zapit.h @@ -75,7 +75,9 @@ class CZapit : public OpenThreads::Thread int video_mode; Zapit_config config; CConfigFile configfile; + CEventServer *eventServer; + CBasicServer zapit_server; CZapitChannel * current_channel; t_channel_id live_channel_id; diff --git a/src/zapit/src/zapit.cpp b/src/zapit/src/zapit.cpp index 5837791f8..f8e276a5a 100644 --- a/src/zapit/src/zapit.cpp +++ b/src/zapit/src/zapit.cpp @@ -27,6 +27,7 @@ #include #include #include +#include #include #include @@ -741,6 +742,7 @@ bool CZapit::ParseCommand(CBasicMessage::Header &rmsg, int connfd) if ((standby) && ((rmsg.cmd != CZapitMessages::CMD_SET_VOLUME) && (rmsg.cmd != CZapitMessages::CMD_MUTE) + && (rmsg.cmd != CZapitMessages::CMD_REGISTEREVENTS) && (rmsg.cmd != CZapitMessages::CMD_IS_TV_CHANNEL) && (rmsg.cmd != CZapitMessages::CMD_SET_STANDBY))) { WARN("cmd %d in standby mode", rmsg.cmd); @@ -2046,15 +2048,20 @@ bool CZapit::Start(Z_start_arg *ZapStart_arg) ca->Start(); eventServer = new CEventServer; + if (!zapit_server.prepare(ZAPIT_UDS_NAME)) { + perror(ZAPIT_UDS_NAME); + return false; + } current_channel = CServiceManager::getInstance()->FindChannel(live_channel_id); // some older? hw needs this sleep. e.g. my hd-1c. // if sleep is not set -> blackscreen after boot. // sleep(1) is ok here. (striper) +#if 0 sleep(1); leaveStandby(); - +#endif started = true; int ret = start(); return (ret == 0); @@ -2081,15 +2088,14 @@ void CZapit::run() printf("[zapit] starting... tid %ld\n", syscall(__NR_gettid)); abort_zapit = 0; - +#if 0 CBasicServer zapit_server; if (!zapit_server.prepare(ZAPIT_UDS_NAME)) { perror(ZAPIT_UDS_NAME); return; } - - //pthread_create (&tsdt, NULL, sdt_thread, (void *) NULL); +#endif SdtMonitor.Start(); while (started && zapit_server.run(zapit_parse_command, CZapitMessages::ACTVERSION, true)) {