SASC-NG
DVBSoftCAM

log.h File Reference

#include "misc.h"

Go to the source code of this file.

Classes

struct  LogConfig
struct  LogModule
struct  LogHeader
class  cLogging
class  cUserMsg
class  cUserMsgs
class  cLogLineBuff

Defines

#define LOPT_NUM   27
#define LOPT_MAX   (1<<LOPT_NUM)
#define LOPT_MASK   (LOPT_MAX-1)
#define LMOD_MAX   (1<<(32-LOPT_NUM))
#define LMOD_MASK   (LMOD_MAX-1)
#define LMOD_ENABLE   1
#define LCLASS(m, o)   ((((m)&LMOD_MASK)<<LOPT_NUM)|((o)&LOPT_MASK))
#define LMOD(c)   (((c)>>LOPT_NUM)&LMOD_MASK)
#define LOPT(o)   ((o)&LOPT_MASK)
#define LALL(o)   (((o)<<1)-1)
#define ADD_MODULE(MOD, NAME)   static bool __add_mod_ ## NAME = cLogging::AddModule(MOD,&NAME);
#define PRINTF(c,...)   cLogging::Printf((c),__VA_ARGS__)
#define PUTS(c, t)   cLogging::Puts((c),(t))
#define PUTLB(c, lb)   cLogging::PutLB((c),(lb))
#define HEXDUMP(c, d, n,...)   cLogging::Dump((c),(d),(n),__VA_ARGS__)
#define LDUMP(c, d, n,...)   cLogging::LineDump((c),(d),(n),__VA_ARGS__)
#define LOG(c)   cLogging::Enabled((c))
#define HexDump(d, n)   do { int __n=(n); HEXDUMP(L_GEN_MISC,(d),__n,"dump: n=%d/0x%04x",__n,__n); } while(0)
#define LBSTART(c)   do { int __c=(c); if(LOG(__c)) { cLogLineBuff __llb(__c)
#define LBSTARTF(c)   do { int __c=(c); { cLogLineBuff __llb(__c)
#define LBPUT(...)   __llb.Printf(__VA_ARGS__)
#define LBFLUSH()   __llb.Flush()
#define LBEND()   } } while(0)
#define L_GEN   0
#define L_GEN_ERROR   LCLASS(L_GEN,0x2)
#define L_GEN_WARN   LCLASS(L_GEN,0x4)
#define L_GEN_INFO   LCLASS(L_GEN,0x8)
#define L_GEN_DEBUG   LCLASS(L_GEN,0x10)
#define L_GEN_MISC   LCLASS(L_GEN,0x20)
#define L_GEN_ALL   LALL(L_GEN_MISC)

Variables

struct LogConfig logcfg
cUserMsgs ums

Define Documentation

#define ADD_MODULE (   MOD,
  NAME 
)    static bool __add_mod_ ## NAME = cLogging::AddModule(MOD,&NAME);

Definition at line 41 of file log.h.

#define HexDump (   d,
  n 
)    do { int __n=(n); HEXDUMP(L_GEN_MISC,(d),__n,"dump: n=%d/0x%04x",__n,__n); } while(0)

Definition at line 51 of file log.h.

Referenced by cTestNagra::Process().

#define L_GEN   0

Definition at line 61 of file log.h.

#define L_GEN_ALL   LALL(L_GEN_MISC)

Definition at line 68 of file log.h.

#define L_GEN_MISC   LCLASS(L_GEN,0x20)

Definition at line 66 of file log.h.

#define LALL (   o)    (((o)<<1)-1)

Definition at line 39 of file log.h.

#define LBFLUSH ( )    __llb.Flush()
#define LCLASS (   m,
  o 
)    ((((m)&LMOD_MASK)<<LOPT_NUM)|((o)&LOPT_MASK))
#define LMOD (   c)    (((c)>>LOPT_NUM)&LMOD_MASK)
#define LMOD_ENABLE   1

Definition at line 34 of file log.h.

Referenced by cLogging::Enabled(), cLogging::GetOptionName(), and cMenuLogSys::ProcessKey().

#define LMOD_MASK   (LMOD_MAX-1)

Definition at line 33 of file log.h.

#define LMOD_MAX   (1<<(32-LOPT_NUM))
#define LOPT (   o)    ((o)&LOPT_MASK)
#define LOPT_MASK   (LOPT_MAX-1)
#define LOPT_MAX   (1<<LOPT_NUM)

Definition at line 30 of file log.h.

#define LOPT_NUM   27
#define PRINTF (   c,
  ... 
)    cLogging::Printf((c),__VA_ARGS__)

Definition at line 43 of file log.h.

Referenced by cCardClientCCcam2::Action(), cSmartCardSlot::Action(), cNetWatcher::Action(), cAction::Action(), cPlainKeys::Action(), cCam::Active(), c6805::AddBreakpoint(), cEcmInfo::AddCaDescr(), cHookManager::AddHook(), cSeca::AdditionalAlgo(), c6805::AddMapper(), cOpenTVModule::AddPart(), cCam::AddPrg(), cEcmShares::AddStatus(), cN2Prov0501::Algo(), cN2Prov0101::Algo(), cRewriter::Alloc(), cNetSocket::Bind(), cGlobal::CaidsChanged(), cCam::cCam(), cDeCSA::cDeCSA(), cTpsKeys::Check(), cScSetup::Check(), cStructLoader::CheckAccess(), cShare::CheckAddProv(), cSystem::CheckECM(), cChannelList::CheckIgnore(), cSmartCard::CheckSctLen(), cStructLoader::CheckUnmodified(), cMsgCache::Clear(), cMapEeprom::cMapEeprom(), cMapMemHW::cMapMemHW(), cMapRom::cMapRom(), cMsgCache::cMsgCache(), cCCcamCard::Connect(), cNetSocket::Connect(), cPidFilter::cPidFilter(), cSatTime::cSatTime(), cN2Timer::Ctrl(), cCwDes::CwL2Des(), cN2Timer::Cycles(), cCCcamCrypt::DcwChecksum(), cST20::Decode(), cSmartCardViaccess::Decode(), cSmartCardSeca::Decode(), cSmartCardNagra::Decode(), cSmartCardCryptoworks::Decode(), cSmartCardConax::Decode(), cTPS::Decrypt(), cTripleDes::Decrypt(), cDeCSA::Decrypt(), cCamCryptNagra::DecryptDT08(), cNagra2::DecryptECM(), cNagra1::DecryptECM(), cNagra2::DecryptEMM(), cNagra1::DecryptEMM(), cCryptoworks::DecryptRSA(), cEcmCache::Delete(), cSmartCardSlotSerial::DeviceClose(), cSmartCardSlotSerial::DeviceIsInserted(), cSmartCardSlotSRPlus::DeviceOpen(), cSmartCardSlotSerial::DeviceOpen(), cSmartCardSlotSRPlus::DevicePTS(), cSmartCardSlotSerial::DevicePTS(), cSmartCardSlotSerial::DeviceRead(), cSmartCardSlotSerial::DeviceSetMode(), cSmartCardSlotSerial::DeviceToggleReset(), cSmartCardSlotSerial::DeviceWrite(), cMapCore::DoMap(), cLogger::Down(), cPrg::DumpCaDescr(), cLogger::EcmStatus(), Emm(), cEcmShares::FindStatus(), cEcmCache::Flush(), cMsgCache::Get(), cCiFrame::GetBuff(), cEcmCache::GetCached(), cOverrideEmmCaid::GetCaid(), cOverrideCat::GetCatEntry(), cSeca2Prov::GetMap(), cEmu::GetPkKeys(), cOverrideEcmPrio::GetPrio(), cST20::GetReg(), cOverrideEcmTable::GetTable(), cOverrideTunnel::GetTunnel(), cTpsKeys::GetV2Key(), cTPSDecrypt::Handle80008003(), cCardClientCamd35::HandleEMMRequest(), cCardClientCamd33::HandleEMMRequest(), cChannelList::Histo(), cPlainKeys::HouseKeeping(), cSmartCardVideoGuard2::Init(), cSmartCardViaccess::Init(), cSmartCardSeca::Init(), cSmartCardNagra::Init(), cSmartCardIrdeto::Init(), cSmartCardCryptoworks::Init(), cSmartCardConax::Init(), cCardClientNewCamd::Init(), cCardClientCCcam2::Init(), cCardClientCCcam::Init(), cSystems::Init(), InitAll(), cScPlugin::Initialize(), cScDevices::Initialize(), cSmartCard::IsoRead(), cSmartCard::IsoWrite(), cSystem::KeyFail(), cSystem::KeyOK(), SCDEVICE::LateInit(), cScDlls::Load(), cScDll::Load(), cSoftCAM::Load(), cStructLoaderPlain::Load(), cStructLoader::Load(), cStructLoader::LoadFinished(), cCardClientRadegast::Login(), cCardClientNewCamd::Login(), cCardClientCCcam2::Login(), cCardClientCCcam::Login(), cCardClientCamd35::Login(), cCardClientCommon::Login(), cCardClientAroureos::Login(), cCardClientCCcam2::Logout(), cAuxSrv::Map(), cFileMap::Map(), cEmuRom10::MathMapHandler(), cEmu::MathMapHandler(), cStructLoader::MTime(), cFeature::NeedsKeyFile(), cFeature::NeedsSmartCard(), cEcmCache::New(), cAction::NewFilter(), cSatTime::Now(), cTransponderTime::Now(), cScDevices::OnPluginLoad(), cStructLoader::OpenFailed(), cSeca2Prov::P(), cTripleDes::PadMessage(), cSmartCardDataVideoGuard2::Parse(), cSmartCardDataViaccess::Parse(), cSmartCardDataNagra::Parse(), cSmartCardDataIrdeto::Parse(), cSmartCardDataCryptoworks::Parse(), cSmartCardDataConax::Parse(), cPlainKeyNagra::Parse(), cOverrideEcmPrio::Parse(), cOverrideIgnore::Parse(), cOverrideTunnel::Parse(), cOverrideEmmTable::Parse(), cOverrideEcmTable::Parse(), cOverrideEmmCaid::Parse(), cOverrideCat::Parse(), cValidityRange::Parse2(), cValidityRange::Parse3(), cSmartCardSlot::ParseAtr(), cSystemViaccess::ParseCADescriptor(), cSystemScViaccess::ParseCADescriptor(), cCardClientCommon::ParseKeyConfig(), cTpsKeys::ParseLinePlain(), cSystemLinkCardClient::ParseLinePlain(), cSmartCardSlots::ParseLinePlain(), cCardClient::ParseStdConfig(), cCardClientCamd35::ParseUserConfig(), cCardClientCommon::ParseUserConfig(), cPlainKeys::PostLoad(), cN2Prov4101::PostProcAU(), cTpsKeys::PreLoad(), cN2Prov::PrintCaps(), cScDvbDevicePlugin::Probe(), cTpsAuHook::Process(), cScCamSlot::Process(), cEcmHandler::Process(), cLogger::Process(), cHookManager::Process(), cN2Prov0501::ProcessBx(), cSystemSeca::ProcessECM(), cSystemFakeNDS::ProcessECM(), cSystemNagra2::ProcessECM(), cSystemNagra::ProcessECM(), cSystemIrd2::ProcessECM(), cSystemIrd::ProcessECM(), cSystemCryptoworks::ProcessECM(), cSystemConax::ProcessECM(), cCardClientRadegast::ProcessECM(), cCardClientNewCamd::ProcessECM(), cCardClientGbox::ProcessECM(), cCardClientCCcam2::ProcessECM(), cCardClientCCcam::ProcessECM(), cSystemCardClient::ProcessECM(), cCardClientCamd35::ProcessECM(), cCardClientCommon::ProcessECM(), cSystemViaccess::ProcessEMM(), cSystemSeca::ProcessEMM(), cSystemNagra2::ProcessEMM(), cSystemNagra::ProcessEMM(), cSystemIrd2::ProcessEMM(), cSystemIrd::ProcessEMM(), cCardClientNewCamd::ProcessEMM(), cCardClientCCcam2::ProcessEMM(), cCardClientCamd35::ProcessEMM(), cChannelList::Purge(), cNetSocket::Read(), cCam::Read(), cSmartCardVideoGuard2::ReadCmdLen(), cSmartCardVideoGuard2::ReadTiers(), cCardClientCamd35::RecvBlock(), cCardClient::RecvMsg(), cCardClientCommon::RecvMsg(), cTPSDecrypt::RegisterAlgo3(), cCmd0cCrypt::Reset(), cSmartCardSlot::Reset(), cCam::Reset(), cScCamSlot::Reset(), cN2Prov0501::RomInit(), cN2Prov0101::RomInit(), cRSA::RSA(), c6805::Run(), cStructLoaderPlain::Save(), cStructLoader::Save(), cCardClient::SendMsg(), cNetSocket::SendTo(), cSmartCard::SerRead(), cSmartCard::SerWrite(), cTransponderTime::Set(), cDeCSA::SetActive(), cDeCSA::SetCaPid(), SCDEVICE::SetChannelDevice(), cCam::SetCWIndex(), cDeCSA::SetDescr(), cSmartCardSlotSerial::SetDtrRts(), cMsgCache::SetMaxFail(), cCmd0cCrypt::SetMode(), cCam::SetPid(), cEcmHandler::SetPrg(), cST20::SetReg(), cEcmHandler::ShiftCwIndex(), cCryptoworks::Signature(), cPrg::SimplifyCaDescr(), SortNanos(), cScPlugin::Start(), cSmartCard::Status(), cScCamSlot::Status(), cScPlugin::Stop(), cEcmHandler::Stop(), cSeca2Prov::T1(), cSeca2Prov::T2(), cSmartCardSlot::Test(), cN2Prov0101::TimerHandler(), cTPSDecrypt::TpsDecrypt(), cPlainKeys::Trigger(), cCam::Tune(), cChannelList::Unique(), cLogger::Up(), cSmartCardSeca::Update(), cSmartCardIrdeto::Update(), cIrdCardInfos::Update(), cPidFilter::Wakeup(), cNetSocket::Write(), cCam::Write(), cCCcamCard::WriteCaPmt(), cCam::WriteCW(), c6805::~c6805(), cAction::~cAction(), cPidFilter::~cPidFilter(), and cScDlls::~cScDlls().

#define PUTLB (   c,
  lb 
)    cLogging::PutLB((c),(lb))

Definition at line 45 of file log.h.

Referenced by cST20::Decode(), and c6805::Run().

#define PUTS (   c,
  t 
)    cLogging::Puts((c),(t))

Definition at line 44 of file log.h.


Variable Documentation

struct LogConfig logcfg

Definition at line 35 of file log.c.

Definition at line 424 of file log.c.

Referenced by cScPlugin::MainThreadHook().

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines