From edb980808c298dae7ca9ccb1c7a37edd38c67967 Mon Sep 17 00:00:00 2001 From: rjongbloed Date: Mon, 2 Apr 2007 05:51:33 +0000 Subject: [PATCH] Tidied some trace logs to assure all have a category (bit before a tab character) set. --- src/codec/opalpluginmgr.cxx | 47 +++++++++++---------- src/h224/h224.cxx | 13 +++--- src/h224/h281.cxx | 5 ++- src/h224/q922.cxx | 62 ++++++++++++++------------- src/h323/gkclient.cxx | 9 ++-- src/h323/h323.cxx | 12 +++--- src/h323/h323annexg.cxx | 100 +++++++++++++++++++++----------------------- src/h323/h323ep.cxx | 20 ++++----- src/h323/h450pdu.cxx | 25 ++++------- src/h323/peclient.cxx | 9 ++-- src/opal/connection.cxx | 9 ++-- src/opal/manager.cxx | 7 +++- src/opal/mediastrm.cxx | 7 +++- src/opal/patch.cxx | 7 +++- src/rtp/jitter.cxx | 5 ++- src/rtp/rtp.cxx | 56 ++++++++++--------------- 16 files changed, 199 insertions(+), 194 deletions(-) diff --git a/src/codec/opalpluginmgr.cxx b/src/codec/opalpluginmgr.cxx index 5d58b0e7..dd122bfd 100644 --- a/src/codec/opalpluginmgr.cxx +++ b/src/codec/opalpluginmgr.cxx @@ -25,6 +25,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 2.19 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.18 2007/03/29 05:20:17 csoutheren * Implement T.38 and fax * @@ -1635,9 +1638,9 @@ OpalPluginCodecManager::OpalPluginCodecManager(PPluginManager * _pluginMgr) for (r = keyList.begin(); r != keyList.end(); ++r) { OpalMediaFormat * instance = OpalMediaFormatFactory::CreateInstance(*r); if (instance == NULL) { - PTRACE(4, "H323PLUGIN\tCannot instantiate opal media format " << *r); + PTRACE(4, "OpalPlugin\nCannot instantiate opal media format " << *r); } else { - PTRACE(4, "H323PLUGIN\tCreating media format " << *r); + PTRACE(4, "OpalPlugin\nCreating media format " << *r); } } } @@ -1649,9 +1652,9 @@ OpalPluginCodecManager::OpalPluginCodecManager(PPluginManager * _pluginMgr) for (r = keyList.begin(); r != keyList.end(); ++r) { H323StaticPluginCodec * instance = PFactory::CreateInstance(*r); if (instance == NULL) { - PTRACE(4, "H323PLUGIN\tCannot instantiate static codec plugin " << *r); + PTRACE(4, "OpalPlugin\nCannot instantiate static codec plugin " << *r); } else { - PTRACE(4, "H323PLUGIN\tLoading static codec plugin " << *r); + PTRACE(4, "OpalPlugin\nLoading static codec plugin " << *r); RegisterStaticCodec(*r, instance->Get_GetAPIFn(), instance->Get_GetCodecFn()); } } @@ -1689,18 +1692,18 @@ void OpalPluginCodecManager::OnLoadPlugin(PDynaLink & dll, INT code) { PluginCodec_GetCodecFunction getCodecs; if (!dll.GetFunction(PString(signatureFunctionName), (PDynaLink::Function &)getCodecs)) { - PTRACE(3, "H323PLUGIN\tPlugin Codec DLL " << dll.GetName() << " is not a plugin codec"); + PTRACE(3, "OpalPlugin\nPlugin Codec DLL " << dll.GetName() << " is not a plugin codec"); return; } unsigned int count; PluginCodec_Definition * codecs = (*getCodecs)(&count, PLUGIN_CODEC_VERSION_FAX); if (codecs == NULL || count == 0) { - PTRACE(3, "H323PLUGIN\tPlugin Codec DLL " << dll.GetName() << " contains no codec definitions"); + PTRACE(3, "OpalPlugin\nPlugin Codec DLL " << dll.GetName() << " contains no codec definitions"); return; } - PTRACE(3, "H323PLUGIN\tLoading plugin codec " << dll.GetName()); + PTRACE(3, "OpalPlugin\nLoading plugin codec " << dll.GetName()); switch (code) { @@ -1727,7 +1730,7 @@ void OpalPluginCodecManager::RegisterStaticCodec( unsigned int count; PluginCodec_Definition * codecs = (*getCodecFn)(&count, PLUGIN_CODEC_VERSION_FAX); if (codecs == NULL || count == 0) { - PTRACE(3, "H323PLUGIN\tStatic codec " << name << " contains no codec definitions"); + PTRACE(3, "OpalPlugin\nStatic codec " << name << " contains no codec definitions"); return; } @@ -1792,13 +1795,13 @@ void OpalPluginCodecManager::RegisterCodecPlugins(unsigned int count, void * _co RegisterPluginPair(&encoder, &decoder); found = TRUE; - PTRACE(2, "H323PLUGIN\tPlugin codec " << encoder.descr << " defined"); + PTRACE(2, "OpalPlugin\nPlugin codec " << encoder.descr << " defined"); break; } } } if (!found && isEncoder) { - PTRACE(2, "H323PLUGIN\tCannot find decoder for plugin encoder " << encoder.descr); + PTRACE(2, "OpalPlugin\nCannot find decoder for plugin encoder " << encoder.descr); } } } @@ -1862,12 +1865,12 @@ void OpalPluginCodecManager::RegisterPluginPair( // add the media format if (defaultSessionID == 0) { - PTRACE(3, "H323PLUGIN\tCodec DLL provides unknown media format " << (int)(encoderCodec->flags & PluginCodec_MediaTypeMask)); + PTRACE(3, "OpalPlugin\nCodec DLL provides unknown media format " << (int)(encoderCodec->flags & PluginCodec_MediaTypeMask)); } else { PString fmtName = CreateCodecName(encoderCodec, FALSE); OpalMediaFormat existingFormat(fmtName); if (existingFormat.IsValid() && existingFormat.GetCodecBaseTime() >= timeStamp) { - PTRACE(3, "H323PLUGIN\tNewer media format " << fmtName << " already exists"); + PTRACE(3, "OpalPlugin\nNewer media format " << fmtName << " already exists"); //AddFormat(existingFormat); } else { if (existingFormat.IsValid()) { @@ -1875,7 +1878,7 @@ void OpalPluginCodecManager::RegisterPluginPair( GetMediaFormatList() -= existingFormat; } - PTRACE(3, "H323PLUGIN\tCreating new media format" << fmtName); + PTRACE(3, "OpalPlugin\nCreating new media format" << fmtName); OpalMediaFormat * mediaFormat = NULL; @@ -1995,7 +1998,7 @@ void OpalPluginCodecManager::RegisterPluginPair( } else { - PTRACE(3, "H323PLUGIN\tAudio plugin defines unsupported clock rate " << encoderCodec->sampleRate); + PTRACE(3, "OpalPlugin\nAudio plugin defines unsupported clock rate " << encoderCodec->sampleRate); } break; case PluginCodec_MediaTypeAudioStreamed: @@ -2010,7 +2013,7 @@ void OpalPluginCodecManager::RegisterPluginPair( } else { - PTRACE(3, "H323PLUGIN\tAudio plugin defines unsupported clock rate " << encoderCodec->sampleRate); + PTRACE(3, "OpalPlugin\nAudio plugin defines unsupported clock rate " << encoderCodec->sampleRate); } break; #endif @@ -2030,7 +2033,7 @@ void OpalPluginCodecManager::RegisterPluginPair( if (encoderCodec->h323CapabilityType == PluginCodec_H323Codec_NoH323 || (hasCodecControl && (retVal == 0)) ) { - PTRACE(3, "H323PLUGIN\tNot adding H.323 capability for plugin codec " << encoderCodec->destFormat << " as this has been specifically disabled"); + PTRACE(3, "OpalPlugin\nNot adding H.323 capability for plugin codec " << encoderCodec->destFormat << " as this has been specifically disabled"); return; } @@ -2065,7 +2068,7 @@ void OpalPluginCodecManager::RegisterCapability(PluginCodec_Definition * encoder } if (map == NULL) { - PTRACE(3, "H323PLUGIN\tCannot create capability for unknown plugin codec media format " << (int)(encoderCodec->flags & PluginCodec_MediaTypeMask)); + PTRACE(3, "OpalPlugin\nCannot create capability for unknown plugin codec media format " << (int)(encoderCodec->flags & PluginCodec_MediaTypeMask)); } else if (encoderCodec->h323CapabilityType != PluginCodec_H323Codec_undefined) { for (PINDEX i = 0; map[i].pluginCapType >= 0; i++) { @@ -2150,7 +2153,7 @@ H323Capability *CreateGenericAudioCap( PluginCodec_H323GenericCodecData * pluginData = (PluginCodec_H323GenericCodecData *)encoderCodec->h323CapabilityData; if(pluginData == NULL ) { - PTRACE(1, "Generic codec information for codec '"<descr<<"' has NULL data field"); + PTRACE(1, "OpalPlugin\nGeneric codec information for codec '"<descr<<"' has NULL data field"); return NULL; } return new H323CodecPluginGenericAudioCapability(encoderCodec, decoderCodec, pluginData); @@ -2209,8 +2212,8 @@ H323Capability *CreateGenericVideoCap( PluginCodec_H323GenericCodecData * pluginData = (PluginCodec_H323GenericCodecData *)encoderCodec->h323CapabilityData; if (pluginData == NULL ) { - PTRACE(1, "Generic codec information for codec '"<descr<<"' has NULL data field"); - return NULL; + PTRACE(1, "OpalPlugin\nGeneric codec information for codec '"<descr<<"' has NULL data field"); + return NULL; } return new H323CodecPluginGenericVideoCapability(encoderCodec, decoderCodec, pluginData); } @@ -2322,7 +2325,7 @@ H323CodecPluginGenericAudioCapability::H323CodecPluginGenericAudioCapability( case PluginCodec_H323GenericParameterDefinition::PluginCodec_GenericParameter_OctetString: case PluginCodec_H323GenericParameterDefinition::PluginCodec_GenericParameter_GenericParameter: default: - PTRACE(1,"Unsupported Generic parameter type "<< ptr->type << " for generic codec " << _encoderCodec->descr ); + PTRACE(1, "OpalPlugin\nUnsupported Generic parameter type "<< ptr->type << " for generic codec " << _encoderCodec->descr); break; } ptr++; @@ -2788,7 +2791,7 @@ H323CodecPluginGenericVideoCapability::H323CodecPluginGenericVideoCapability( case PluginCodec_H323GenericParameterDefinition::PluginCodec_GenericParameter_OctetString: case PluginCodec_H323GenericParameterDefinition::PluginCodec_GenericParameter_GenericParameter: default: - PTRACE(1,"Unsupported Generic parameter type "<< ptr->type << " for generic codec " << _encoderCodec->descr ); + PTRACE(1, "OpalPlugin\nUnsupported Generic parameter type "<< ptr->type << " for generic codec " << _encoderCodec->descr ); break; } ptr++; diff --git a/src/h224/h224.cxx b/src/h224/h224.cxx index 0fb41407..aa4ed055 100644 --- a/src/h224/h224.cxx +++ b/src/h224/h224.cxx @@ -19,6 +19,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 1.5 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 1.4 2007/03/12 23:19:01 csoutheren * Add ability to remove H.224 * @@ -295,7 +298,7 @@ void OpalH224Handler::StopTransmit() void OpalH224Handler::StartReceive() { if(receiverThread != NULL) { - PTRACE(5, "H.224 handler is already receiving"); + PTRACE(2, "H.224\tHandler is already receiving"); return; } @@ -492,7 +495,7 @@ BOOL OpalH224Handler::OnReceivedFrame(H224_Frame & frame) { if(frame.GetDestinationTerminalAddress() != H224_BROADCAST) { // only broadcast frames are handled at the moment - PTRACE(3, "Received H.224 frame with non-broadcast address"); + PTRACE(3, "H.224\tReceived frame with non-broadcast address"); return TRUE; } BYTE clientID = frame.GetClientID(); @@ -603,7 +606,7 @@ void OpalH224Handler::TransmitFrame(H224_Frame & frame) PINDEX size = frame.GetEncodedSize(); if(!frame.Encode(transmitFrame->GetPayloadPtr(), size, transmitBitIndex)) { - PTRACE(3, "Failed to encode H.224 frame"); + PTRACE(2, "H.224\tFailed to encode frame"); return; } @@ -616,7 +619,7 @@ void OpalH224Handler::TransmitFrame(H224_Frame & frame) transmitFrame->SetMarker(TRUE); if(!session->WriteData(*transmitFrame)) { - PTRACE(3, "Failed to write encoded H.224 frame"); + PTRACE(2, "H.224\tFailed to write encoded frame"); } } @@ -659,7 +662,7 @@ void OpalH224ReceiverThread::Main() return; } } else { - PTRACE(3, "Decoding of H.224 frame failed"); + PTRACE(2, "H.224\tDecoding of frame failed"); } inUse.Signal(); diff --git a/src/h224/h281.cxx b/src/h224/h281.cxx index f2ea5d69..47d81b26 100644 --- a/src/h224/h281.cxx +++ b/src/h224/h281.cxx @@ -19,6 +19,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 1.6 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 1.5 2007/03/30 02:09:50 rjongbloed * Fixed various GCC warnings * @@ -740,7 +743,7 @@ void OpalH281Handler::OnReceivedMessage(const H281_Frame & message) OnActivatePreset(message.GetPresetNumber()); } else { - PTRACE(3, "H.281: Unknown Request: " << requestType); + PTRACE(3, "H.281\tUnknown Request: " << requestType); } } diff --git a/src/h224/q922.cxx b/src/h224/q922.cxx index 9eda632b..0b0bf721 100644 --- a/src/h224/q922.cxx +++ b/src/h224/q922.cxx @@ -19,6 +19,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 1.6 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 1.5 2007/03/12 23:19:01 csoutheren * Add ability to remove H.224 * @@ -120,67 +123,66 @@ BOOL Q922_Frame::Decode(const BYTE *data, PINDEX size) // 2 octets FCS and at least 1 octet information if(size < 2+3+2+1) return FALSE; - + PINDEX octetIndex = 0; BYTE bitIndex = 7; BYTE onesCounter = 0; - + if(!FindFlagEnd(data, size, octetIndex, bitIndex)) - return FALSE; - + return FALSE; + BYTE firstOctet; BYTE secondOctet; - + // read the two first octets if(octetIndex >= size || DecodeByte(data, &firstOctet, octetIndex, bitIndex, onesCounter) != Q922_OK) return FALSE; - + if(octetIndex >= size || DecodeByte(data, &secondOctet, octetIndex, bitIndex, onesCounter) != Q922_OK) - return FALSE; - + return FALSE; + PINDEX arrayIndex = 0; while(octetIndex < size) { - + BYTE decodedByte; BYTE result = DecodeByte(data, &decodedByte, octetIndex, bitIndex, onesCounter); - - if(result == Q922_ERROR) { - return FALSE; - } else if(result == Q922_FLAG) { - + if(result == Q922_ERROR) + return FALSE; + + if(result == Q922_FLAG) { + // Found end flag // FCS is contained in firstOctet and secondOctet. WORD fcs = (secondOctet << 8) | firstOctet; - + // Calculate FCS from data to check WORD calculatedFCS = CalculateFCS((const BYTE *)theArray, arrayIndex); - - if(fcs != calculatedFCS) { - PTRACE(3, "Q.922 frame has incorrect checksum"); - return FALSE; + + if (fcs != calculatedFCS) { + PTRACE(2, "Q.922\tFrame has incorrect checksum"); + return FALSE; } - + if(arrayIndex > Q922_HEADER_SIZE) { SetInformationFieldSize(arrayIndex - Q922_HEADER_SIZE); return TRUE; } - - return FALSE; - } - + + return FALSE; + } + theArray[arrayIndex] = firstOctet; arrayIndex++; - + firstOctet = secondOctet; secondOctet = decodedByte; - - // Q922-frames must not exceed an information field size of 260 octets - if(arrayIndex >= 260+Q922_HEADER_SIZE) { + + // Q922-frames must not exceed an information field size of 260 octets + if(arrayIndex >= 260+Q922_HEADER_SIZE) return FALSE; - } } - + return FALSE; } diff --git a/src/h323/gkclient.cxx b/src/h323/gkclient.cxx index 15a0b516..a04d8c29 100644 --- a/src/h323/gkclient.cxx +++ b/src/h323/gkclient.cxx @@ -27,6 +27,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 2.36 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.35 2006/07/28 10:41:50 rjongbloed * Fixed DevStudio 2005 warnings on time_t conversions. * @@ -1682,13 +1685,13 @@ static void ExtractToken(const AdmissionRequestResponseInfo & info, PBYTEArray & accessTokenData) { if (!info.accessTokenOID1 && tokens.GetSize() > 0) { - PTRACE(4, "Looking for OID " << info.accessTokenOID1 << " in ACF to copy."); + PTRACE(4, "RAS\tLooking for OID " << info.accessTokenOID1 << " in ACF to copy."); for (PINDEX i = 0; i < tokens.GetSize(); i++) { if (tokens[i].m_tokenOID == info.accessTokenOID1) { - PTRACE(4, "Looking for OID " << info.accessTokenOID2 << " in token to copy."); + PTRACE(4, "RAS\tLooking for OID " << info.accessTokenOID2 << " in token to copy."); if (tokens[i].HasOptionalField(H235_ClearToken::e_nonStandard) && tokens[i].m_nonStandard.m_nonStandardIdentifier == info.accessTokenOID2) { - PTRACE(4, "Copying ACF nonStandard OctetString."); + PTRACE(4, "RAS\tCopying ACF nonStandard OctetString."); accessTokenData = tokens[i].m_nonStandard.m_data; break; } diff --git a/src/h323/h323.cxx b/src/h323/h323.cxx index 8bcd89d0..86469925 100644 --- a/src/h323/h323.cxx +++ b/src/h323/h323.cxx @@ -24,6 +24,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 2.146 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.145 2007/03/29 05:16:49 csoutheren * Pass OpalConnection to OpalMediaSream constructor * Add ID to OpalMediaStreams so that transcoders can match incoming and outgoing codecs @@ -246,11 +249,6 @@ const PTimeInterval MonitorCallStatusTime(0, 10); // Seconds #define new PNEW -#if !PTRACING // Stuff to remove unised parameters warning -#define PTRACE_pdu -#endif - - ///////////////////////////////////////////////////////////////////////////// #if PTRACING @@ -2490,9 +2488,9 @@ BOOL H323Connection::HandleFastStartAcknowledge(const H225_ArrayOf_PASN_OctetStr } -BOOL H323Connection::OnUnknownSignalPDU(const H323SignalPDU & PTRACE_pdu) +BOOL H323Connection::OnUnknownSignalPDU(const H323SignalPDU & PTRACE_PARAM(pdu)) { - PTRACE(2, "H225\tUnknown signalling PDU: " << PTRACE_pdu); + PTRACE(2, "H225\tUnknown signalling PDU: " << pdu); return TRUE; } diff --git a/src/h323/h323annexg.cxx b/src/h323/h323annexg.cxx index 50410f13..bc4ac6fd 100644 --- a/src/h323/h323annexg.cxx +++ b/src/h323/h323annexg.cxx @@ -24,6 +24,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 2.2 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.1 2004/02/19 10:47:04 rjongbloed * Merged OpenH323 version 1.13.1 changes. * @@ -79,13 +82,6 @@ #include -#if PTRACING -#define PTRACE_pdu pdu -#else -#define PTRACE_pdu -#endif - - #define new PNEW @@ -305,45 +301,45 @@ BOOL H323_AnnexG::OnReceiveServiceRelease(const H501PDU & /*common*/, const H501 return FALSE; } -BOOL H323_AnnexG::OnReceiveDescriptorRequest(const H501PDU & PTRACE_pdu, const H501_DescriptorRequest & /*pdu*/) +BOOL H323_AnnexG::OnReceiveDescriptorRequest(const H501PDU & PTRACE_PARAM(pdu), const H501_DescriptorRequest & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveDescriptorRequest - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveDescriptorRequest - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveDescriptorConfirmation(const H501PDU & PTRACE_pdu, const H501_DescriptorConfirmation & /*pdu*/) +BOOL H323_AnnexG::OnReceiveDescriptorConfirmation(const H501PDU & PTRACE_PARAM(pdu), const H501_DescriptorConfirmation & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveDescriptorConfirmation - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveDescriptorConfirmation - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveDescriptorRejection(const H501PDU & PTRACE_pdu, const H501_DescriptorRejection & /*pdu*/) +BOOL H323_AnnexG::OnReceiveDescriptorRejection(const H501PDU & PTRACE_PARAM(pdu), const H501_DescriptorRejection & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveDescriptorRejection - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveDescriptorRejection - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveDescriptorIDRequest(const H501PDU & PTRACE_pdu, const H501_DescriptorIDRequest & /*pdu*/) +BOOL H323_AnnexG::OnReceiveDescriptorIDRequest(const H501PDU & PTRACE_PARAM(pdu), const H501_DescriptorIDRequest & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveDescriptorIDRequest - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveDescriptorIDRequest - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveDescriptorIDConfirmation(const H501PDU & PTRACE_pdu, const H501_DescriptorIDConfirmation & /*pdu*/) +BOOL H323_AnnexG::OnReceiveDescriptorIDConfirmation(const H501PDU & PTRACE_PARAM(pdu), const H501_DescriptorIDConfirmation & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveDescriptorIDConfirmation - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveDescriptorIDConfirmation - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveDescriptorIDRejection(const H501PDU & PTRACE_pdu, const H501_DescriptorIDRejection & /*pdu*/) +BOOL H323_AnnexG::OnReceiveDescriptorIDRejection(const H501PDU & PTRACE_PARAM(pdu), const H501_DescriptorIDRejection & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveDescriptorIDRejection - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveDescriptorIDRejection - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveDescriptorUpdate(const H501PDU & PTRACE_pdu, const H501_DescriptorUpdate & /*pdu*/) +BOOL H323_AnnexG::OnReceiveDescriptorUpdate(const H501PDU & PTRACE_PARAM(pdu), const H501_DescriptorUpdate & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveDescriptorUpdate - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveDescriptorUpdate - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } @@ -353,9 +349,9 @@ BOOL H323_AnnexG::OnReceiveDescriptorUpdateACK(const H501PDU & pdu, const H501_D return CheckForResponse(H501_MessageBody::e_descriptorUpdate, pdu.m_common.m_sequenceNumber); } -BOOL H323_AnnexG::OnReceiveAccessRequest(const H501PDU & PTRACE_pdu, const H501_AccessRequest & /*pdu*/) +BOOL H323_AnnexG::OnReceiveAccessRequest(const H501PDU & PTRACE_PARAM(pdu), const H501_AccessRequest & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveAccessRequest - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveAccessRequest - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } @@ -376,93 +372,93 @@ BOOL H323_AnnexG::OnReceiveRequestInProgress(const H501PDU & pdu, const H501_Req return HandleRequestInProgress(pdu, rip.m_delay); } -BOOL H323_AnnexG::OnReceiveNonStandardRequest(const H501PDU & PTRACE_pdu, const H501_NonStandardRequest & /*pdu*/) +BOOL H323_AnnexG::OnReceiveNonStandardRequest(const H501PDU & PTRACE_PARAM(pdu), const H501_NonStandardRequest & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveNonStandardRequest - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveNonStandardRequest - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveNonStandardConfirmation(const H501PDU & PTRACE_pdu, const H501_NonStandardConfirmation & /*pdu*/) +BOOL H323_AnnexG::OnReceiveNonStandardConfirmation(const H501PDU & PTRACE_PARAM(pdu), const H501_NonStandardConfirmation & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveNonStandardConfirmation - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveNonStandardConfirmation - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveNonStandardRejection(const H501PDU & PTRACE_pdu, const H501_NonStandardRejection & /*pdu*/) +BOOL H323_AnnexG::OnReceiveNonStandardRejection(const H501PDU & PTRACE_PARAM(pdu), const H501_NonStandardRejection & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveNonStandardRejection - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveNonStandardRejection - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveUnknownMessageResponse(const H501PDU & PTRACE_pdu, const H501_UnknownMessageResponse & /*pdu*/) +BOOL H323_AnnexG::OnReceiveUnknownMessageResponse(const H501PDU & PTRACE_PARAM(pdu), const H501_UnknownMessageResponse & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveUnknownMessageResponse - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveUnknownMessageResponse - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveUsageRequest(const H501PDU & PTRACE_pdu, const H501_UsageRequest & /*pdu*/) +BOOL H323_AnnexG::OnReceiveUsageRequest(const H501PDU & PTRACE_PARAM(pdu), const H501_UsageRequest & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveUsageRequest - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveUsageRequest - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveUsageConfirmation(const H501PDU & PTRACE_pdu, const H501_UsageConfirmation & /*pdu*/) +BOOL H323_AnnexG::OnReceiveUsageConfirmation(const H501PDU & PTRACE_PARAM(pdu), const H501_UsageConfirmation & /*pdu*/) { PTRACE(3, "AnnexG\tOnReceiveUsageConfirmation - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveUsageIndicationConfirmation(const H501PDU & PTRACE_pdu, const H501_UsageIndicationConfirmation & /*pdu*/) +BOOL H323_AnnexG::OnReceiveUsageIndicationConfirmation(const H501PDU & PTRACE_PARAM(pdu), const H501_UsageIndicationConfirmation & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveUsageIndicationConfirmation - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveUsageIndicationConfirmation - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveUsageIndicationRejection(const H501PDU & PTRACE_pdu, const H501_UsageIndicationRejection & /*pdu*/) +BOOL H323_AnnexG::OnReceiveUsageIndicationRejection(const H501PDU & PTRACE_PARAM(pdu), const H501_UsageIndicationRejection & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveUsageIndicationRejection - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveUsageIndicationRejection - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveUsageRejection(const H501PDU & PTRACE_pdu, const H501_UsageRejection & /*pdu*/) +BOOL H323_AnnexG::OnReceiveUsageRejection(const H501PDU & PTRACE_PARAM(pdu), const H501_UsageRejection & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveUsageRejection - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveUsageRejection - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveValidationRequest(const H501PDU & PTRACE_pdu, const H501_ValidationRequest & /*pdu*/) +BOOL H323_AnnexG::OnReceiveValidationRequest(const H501PDU & PTRACE_PARAM(pdu), const H501_ValidationRequest & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveValidationRequest - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveValidationRequest - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveValidationConfirmation(const H501PDU & PTRACE_pdu, const H501_ValidationConfirmation & /*pdu*/) +BOOL H323_AnnexG::OnReceiveValidationConfirmation(const H501PDU & PTRACE_PARAM(pdu), const H501_ValidationConfirmation & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveValidationConfirmation - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveValidationConfirmation - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveValidationRejection(const H501PDU & PTRACE_pdu, const H501_ValidationRejection & /*pdu*/) +BOOL H323_AnnexG::OnReceiveValidationRejection(const H501PDU & PTRACE_PARAM(pdu), const H501_ValidationRejection & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveValidationRejection - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveValidationRejection - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveAuthenticationRequest(const H501PDU & PTRACE_pdu, const H501_AuthenticationRequest & /*pdu*/) +BOOL H323_AnnexG::OnReceiveAuthenticationRequest(const H501PDU & PTRACE_PARAM(pdu), const H501_AuthenticationRequest & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveAuthenticationRequest - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveAuthenticationRequest - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveAuthenticationConfirmation(const H501PDU & PTRACE_pdu, const H501_AuthenticationConfirmation & /*pdu*/) +BOOL H323_AnnexG::OnReceiveAuthenticationConfirmation(const H501PDU & PTRACE_PARAM(pdu), const H501_AuthenticationConfirmation & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveAuthenticationConfirmation - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveAuthenticationConfirmation - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } -BOOL H323_AnnexG::OnReceiveAuthenticationRejection(const H501PDU & PTRACE_pdu, const H501_AuthenticationRejection & /*pdu*/) +BOOL H323_AnnexG::OnReceiveAuthenticationRejection(const H501PDU & PTRACE_PARAM(pdu), const H501_AuthenticationRejection & /*pdu*/) { - PTRACE(3, "AnnexG\tOnReceiveAuthenticationRejection - seq: " << PTRACE_pdu.m_common.m_sequenceNumber); + PTRACE(3, "AnnexG\tOnReceiveAuthenticationRejection - seq: " << pdu.m_common.m_sequenceNumber); return FALSE; } diff --git a/src/h323/h323ep.cxx b/src/h323/h323ep.cxx index 3be0b930..bd5189f1 100644 --- a/src/h323/h323ep.cxx +++ b/src/h323/h323ep.cxx @@ -27,6 +27,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 2.66 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.65 2007/03/29 23:55:46 rjongbloed * Tidied some code when a new connection is created by an endpoint. Now * if someone needs to derive a connection class they can create it without @@ -146,15 +149,12 @@ #define new PNEW -#if !PTRACING // Stuff to remove unised parameters warning -#define PTRACE_isEncoding -#define PTRACE_channel -#endif BYTE H323EndPoint::defaultT35CountryCode = 9; // Country code for Australia BYTE H323EndPoint::defaultT35Extension = 0; WORD H323EndPoint::defaultManufacturerCode = 61; // Allocated by Australian Communications Authority, Oct 2000; + ///////////////////////////////////////////////////////////////////////////// H323EndPoint::H323EndPoint(OpalManager & manager, const char * _prefix, WORD _defaultSignalPort) @@ -553,7 +553,7 @@ H235Authenticators H323EndPoint::CreateAuthenticators() for (r = keyList.begin(); r != keyList.end(); ++r) authenticators.Append(PFactory::CreateInstance(*r)); - PTRACE(1, "Authenticator list is size " << (int)authenticators.GetSize()); + PTRACE(3, "H323\tAuthenticator list is size " << (int)authenticators.GetSize()); return authenticators; } @@ -565,7 +565,7 @@ BOOL H323EndPoint::MakeConnection(OpalCall & call, unsigned int options, OpalConnection::StringOptions * stringOptions) { - PTRACE(2, "H323\tMaking call to: " << remoteParty); + PTRACE(3, "H323\tMaking call to: " << remoteParty); return InternalMakeCall(call, PString::Empty(), PString::Empty(), @@ -1190,20 +1190,20 @@ static void OnStartStopChannel(const char * startstop, const H323Channel & chann BOOL H323EndPoint::OnStartLogicalChannel(H323Connection & /*connection*/, - H323Channel & PTRACE_channel) + H323Channel & PTRACE_PARAM(channel)) { #if PTRACING - OnStartStopChannel("Start", PTRACE_channel); + OnStartStopChannel("Start", channel); #endif return TRUE; } void H323EndPoint::OnClosedLogicalChannel(H323Connection & /*connection*/, - const H323Channel & PTRACE_channel) + const H323Channel & PTRACE_PARAM(channel)) { #if PTRACING - OnStartStopChannel("Stopp", PTRACE_channel); + OnStartStopChannel("Stopp", channel); #endif } diff --git a/src/h323/h450pdu.cxx b/src/h323/h450pdu.cxx index eb70ed4b..103948c9 100644 --- a/src/h323/h450pdu.cxx +++ b/src/h323/h450pdu.cxx @@ -24,6 +24,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 2.21 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.20 2007/03/30 02:09:53 rjongbloed * Fixed various GCC warnings * @@ -2477,16 +2480,10 @@ BOOL H45011Handler::OnReceivedInvokeReturnError(int errorCode, const bool timerE } -#if PTRACING -#define PTRACE_errorCode errorCode -#else -#define PTRACE_errorCode -#endif - -BOOL H45011Handler::OnReceivedGetCIPLReturnError(int PTRACE_errorCode, +BOOL H45011Handler::OnReceivedGetCIPLReturnError(int PTRACE_PARAM(errorCode), const bool timerExpiry) { - PTRACE(4, "H450.11\tOnReceivedGetCIPLReturnError ErrorCode=" << PTRACE_errorCode); + PTRACE(4, "H450.11\tOnReceivedGetCIPLReturnError ErrorCode=" << errorCode); if(!timerExpiry){ if (ciTimer.IsRunning()){ ciTimer.Stop(); @@ -2625,18 +2622,10 @@ void H45011Handler::OnCallIntrudeTimeOut(PTimer &, INT) } -#if PTRACING -#define PTRACE_problemType problemType -#define PTRACE_problemNumber problemNumber -#else -#define PTRACE_problemType -#define PTRACE_problemNumber -#endif - -BOOL H45011Handler::OnReceivedReject(int PTRACE_problemType, int PTRACE_problemNumber) +BOOL H45011Handler::OnReceivedReject(int PTRACE_PARAM(problemType), int PTRACE_PARAM(problemNumber)) { PTRACE(4, "H450.11\tH45011Handler::OnReceivedReject - problemType= " - << PTRACE_problemType << ", problemNumber= " << PTRACE_problemNumber); + << problemType << ", problemNumber= " << problemNumber); if (ciTimer.IsRunning()){ ciTimer.Stop(); diff --git a/src/h323/peclient.cxx b/src/h323/peclient.cxx index efe82fc0..6720a0a0 100644 --- a/src/h323/peclient.cxx +++ b/src/h323/peclient.cxx @@ -24,6 +24,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 2.3 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.2 2004/06/04 06:54:18 csoutheren * Migrated updates from OpenH323 1.14.1 * @@ -758,7 +761,7 @@ H323Transaction::Response H323PeerElement::HandleServiceRequest(H501ServiceReque OpalGloballyUniqueID serviceID(info.requestCommon.m_serviceID); PSafePtr sr = localServiceRelationships.FindWithLock(H323PeerElementServiceRelationship(serviceID), PSafeReadWrite); if (sr == NULL) { - PTRACE(2, "PeerElement\nRejecting unknown service ID " << serviceID << " received from peer " << info.GetReplyAddress()); + PTRACE(2, "PeerElement\tRejecting unknown service ID " << serviceID << " received from peer " << info.GetReplyAddress()); info.SetRejectReason(H501_ServiceRejectionReason::e_unknownServiceID); return H323Transaction::Reject; } @@ -775,7 +778,7 @@ H323Transaction::Response H323PeerElement::HandleServiceRequest(H501ServiceReque sr->lastUpdateTime = PTime(); sr->expireTime = PTime() + (info.scf.m_timeToLive * 1000); - PTRACE(2, "PeerElement\nService relationship with " << sr->name << " at " << info.GetReplyAddress() << " updated - next update in " << info.scf.m_timeToLive); + PTRACE(2, "PeerElement\tService relationship with " << sr->name << " at " << info.GetReplyAddress() << " updated - next update in " << info.scf.m_timeToLive); return H323Transaction::Confirm; } @@ -817,7 +820,7 @@ H323Transaction::Response H323PeerElement::HandleServiceRequest(H501ServiceReque monitorTickle.Signal(); // send the response - PTRACE(2, "PeerElement\nNew service relationship with " << sr->name << " at " << info.GetReplyAddress() << " created - next update in " << info.scf.m_timeToLive); + PTRACE(3, "PeerElement\tNew service relationship with " << sr->name << " at " << info.GetReplyAddress() << " created - next update in " << info.scf.m_timeToLive); return H323Transaction::Confirm; } diff --git a/src/opal/connection.cxx b/src/opal/connection.cxx index 2eabd888..71e0ba36 100644 --- a/src/opal/connection.cxx +++ b/src/opal/connection.cxx @@ -25,6 +25,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 2.101 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.100 2007/03/30 02:09:53 rjongbloed * Fixed various GCC warnings * @@ -881,7 +884,7 @@ BOOL OpalConnection::OpenSourceMediaStream(const OpalMediaFormatList & mediaForm if (stream->Open()) { if (OnOpenMediaStream(*stream)) { - PTRACE(1, "Opened source stream " << stream->GetID()); + PTRACE(3, "OpalCon\tOpened source stream " << stream->GetID()); return TRUE; } PTRACE(2, "OpalCon\tSource media OnOpenMediaStream open of " << sourceFormat << " failed."); @@ -941,7 +944,7 @@ OpalMediaStream * OpalConnection::OpenSinkMediaStream(OpalMediaStream & source) if (stream->Open()) { if (OnOpenMediaStream(*stream)) { - PTRACE(1, "Opened sink stream " << stream->GetID()); + PTRACE(3, "OpalCon\tOpened sink stream " << stream->GetID()); return stream; } PTRACE(2, "OpalCon\tSink media stream OnOpenMediaStream of " << destinationFormat << " failed."); @@ -1479,7 +1482,7 @@ void OpalConnection::OnUserInputInBandDTMF(RTP_DataFrame & frame, INT) // Pass the 16 bit PCM audio through the DTMF decoder PString tones = dtmfDecoder.Decode((const short *)frame.GetPayloadPtr(), frame.GetPayloadSize()/sizeof(short)); if (!tones.IsEmpty()) { - PTRACE(1, "DTMF detected. " << tones); + PTRACE(1, "OPAL\tDTMF detected. " << tones); PINDEX i; for (i = 0; i < tones.GetLength(); i++) { OnUserInputTone(tones[i], 0); diff --git a/src/opal/manager.cxx b/src/opal/manager.cxx index d8f9e76d..a369c55a 100644 --- a/src/opal/manager.cxx +++ b/src/opal/manager.cxx @@ -25,6 +25,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 2.78 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.77 2007/03/21 16:10:46 hfriederich * Use CallEndReason from connection if call setup fails * @@ -533,7 +536,7 @@ BOOL OpalManager::SetUpCall(const PString & partyA, // B-Party then SetUpConnection() gets called in the context of the A-party // thread. if (MakeConnection(*call, partyA, userData, options, stringOptions) && call->GetConnection(0)->SetUpConnection()) { - PTRACE(1, "SetUpCall succeeded, call=" << *call); + PTRACE(3, "OpalMan\tSetUpCall succeeded, call=" << *call); return TRUE; } @@ -550,7 +553,7 @@ BOOL OpalManager::SetUpCall(const PString & partyA, } if (!activeCalls.RemoveAt(token)) { - PTRACE(1, "SetUpCall could not remove call from active call list"); + PTRACE(1, "OpalMan\tSetUpCall could not remove call from active call list"); } token.MakeEmpty(); diff --git a/src/opal/mediastrm.cxx b/src/opal/mediastrm.cxx index fe9247b7..c754a8c1 100644 --- a/src/opal/mediastrm.cxx +++ b/src/opal/mediastrm.cxx @@ -24,6 +24,9 @@ * Contributor(s): ________________________________________. * * $Log$ + * Revision 2.54 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.53 2007/03/29 05:16:50 csoutheren * Pass OpalConnection to OpalMediaSream constructor * Add ID to OpalMediaStreams so that transcoders can match incoming and outgoing codecs @@ -1134,7 +1137,7 @@ BOOL OpalUDPMediaStream::ReadPacket(RTP_DataFrame & Packet) PBYTEArray rawData; if (!udpTransport.ReadPDU(rawData)) { - PTRACE(3, "Read on UDP transport failed: " + PTRACE(2, "Media\tRead on UDP transport failed: " << udpTransport.GetErrorText() << " transport: " << udpTransport); return FALSE; } @@ -1156,7 +1159,7 @@ BOOL OpalUDPMediaStream::WritePacket(RTP_DataFrame & Packet) if (Packet.GetPayloadSize() > 0) { if (!udpTransport.Write(Packet.GetPayloadPtr(), Packet.GetPayloadSize())) { - PTRACE(3, "Media\tWrite on UDP transport failed: " + PTRACE(2, "Media\tWrite on UDP transport failed: " << udpTransport.GetErrorText() << " transport: " << udpTransport); return FALSE; } diff --git a/src/opal/patch.cxx b/src/opal/patch.cxx index 324e3b07..3e279c0b 100644 --- a/src/opal/patch.cxx +++ b/src/opal/patch.cxx @@ -25,6 +25,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 2.45 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.44 2007/03/29 08:30:21 csoutheren * Avoid problem with T.38 codecs * @@ -329,7 +332,7 @@ BOOL OpalMediaPatch::AddSink(OpalMediaStream * stream, const RTP_DataFrame::Payl PString id = stream->GetID(); sink->primaryCodec = OpalTranscoder::Create(sourceFormat, destinationFormat, (const BYTE *)id, id.GetLength()); if (sink->primaryCodec != NULL) { - PTRACE(1, "created primary codec " << sourceFormat << "/" << destinationFormat << " with ID " << id); + PTRACE(4, "Patch\tCreated primary codec " << sourceFormat << "/" << destinationFormat << " with ID " << id); sink->primaryCodec->SetRTPPayloadMap(rtpMap); sink->primaryCodec->SetMaxOutputSize(stream->GetDataSize()); @@ -353,7 +356,7 @@ BOOL OpalMediaPatch::AddSink(OpalMediaStream * stream, const RTP_DataFrame::Payl sink->primaryCodec = OpalTranscoder::Create(sourceFormat, intermediateFormat, (const BYTE *)id, id.GetLength()); sink->secondaryCodec = OpalTranscoder::Create(intermediateFormat, destinationFormat, (const BYTE *)id, id.GetLength()); - PTRACE(1, "created two stage codec " << sourceFormat << "/" << intermediateFormat << "/" << destinationFormat << " with ID " << id); + PTRACE(4, "Patch\tcreated two stage codec " << sourceFormat << "/" << intermediateFormat << "/" << destinationFormat << " with ID " << id); sink->secondaryCodec->SetMaxOutputSize(sink->stream->GetDataSize()); diff --git a/src/rtp/jitter.cxx b/src/rtp/jitter.cxx index 0a70ddc7..48a8eb75 100644 --- a/src/rtp/jitter.cxx +++ b/src/rtp/jitter.cxx @@ -27,6 +27,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 2.18 2007/04/02 05:51:33 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.17 2007/01/15 21:32:54 rjongbloed * Fixed minor (and generally benign) bug in jitter buffer SetDelay, should use same time base as * constructor for calculating number of buffers @@ -425,7 +428,7 @@ OpalJitterBuffer::~OpalJitterBuffer() #if PTRACING && !defined(NO_ANALYSER) - PTRACE(5, "Jitter buffer analysis: size=" << bufferSize + PTRACE(5, "RTP\tJitter buffer analysis: size=" << bufferSize << " time=" << currentJitterTime << '\n' << *analyser); delete analyser; #endif diff --git a/src/rtp/rtp.cxx b/src/rtp/rtp.cxx index f8e5a269..5ba41488 100644 --- a/src/rtp/rtp.cxx +++ b/src/rtp/rtp.cxx @@ -27,6 +27,9 @@ * Contributor(s): ______________________________________. * * $Log$ + * Revision 2.58 2007/04/02 05:51:34 rjongbloed + * Tidied some trace logs to assure all have a category (bit before a tab character) set. + * * Revision 2.57 2007/03/29 23:53:39 rjongbloed * Fixed log message about swallowing UDP packets so only prints out * if non-zero packets were swallowed. @@ -533,19 +536,6 @@ #define new PNEW -#if !PTRACING // Stuff to remove unised parameters warning -#define PTRACE_sender -#define PTRACE_reports -#define PTRACE_count -#define PTRACE_src -#define PTRACE_description -#define PTRACE_reason -#define PTRACE_type -#define PTRACE_subtype -#define PTRACE_size -#define PTRACE_port -#endif - const unsigned SecondsFrom1900to1970 = (70*365+17)*24*60*60U; @@ -1645,49 +1635,49 @@ RTP_Session::SendReceiveStatus RTP_Session::OnReceiveControl(RTP_ControlFrame & } -void RTP_Session::OnRxSenderReport(const SenderReport & PTRACE_sender, - const ReceiverReportArray & PTRACE_reports) +void RTP_Session::OnRxSenderReport(const SenderReport & PTRACE_PARAM(sender), + const ReceiverReportArray & PTRACE_PARAM(reports)) { #if PTRACING - PTRACE(3, "RTP\tOnRxSenderReport: " << PTRACE_sender); - for (PINDEX i = 0; i < PTRACE_reports.GetSize(); i++) - PTRACE(3, "RTP\tOnRxSenderReport RR: " << PTRACE_reports[i]); + PTRACE(3, "RTP\tOnRxSenderReport: " << sender); + for (PINDEX i = 0; i < reports.GetSize(); i++) + PTRACE(3, "RTP\tOnRxSenderReport RR: " << reports[i]); #endif } -void RTP_Session::OnRxReceiverReport(DWORD PTRACE_src, - const ReceiverReportArray & PTRACE_reports) +void RTP_Session::OnRxReceiverReport(DWORD PTRACE_PARAM(src), + const ReceiverReportArray & PTRACE_PARAM(reports)) { #if PTRACING - PTRACE(3, "RTP\tOnReceiverReport: ssrc=" << PTRACE_src); - for (PINDEX i = 0; i < PTRACE_reports.GetSize(); i++) - PTRACE(3, "RTP\tOnReceiverReport RR: " << PTRACE_reports[i]); + PTRACE(3, "RTP\tOnReceiverReport: ssrc=" << src); + for (PINDEX i = 0; i < reports.GetSize(); i++) + PTRACE(3, "RTP\tOnReceiverReport RR: " << reports[i]); #endif } -void RTP_Session::OnRxSourceDescription(const SourceDescriptionArray & PTRACE_description) +void RTP_Session::OnRxSourceDescription(const SourceDescriptionArray & PTRACE_PARAM(description)) { #if PTRACING - for (PINDEX i = 0; i < PTRACE_description.GetSize(); i++) - PTRACE(3, "RTP\tOnSourceDescription: " << PTRACE_description[i]); + for (PINDEX i = 0; i < description.GetSize(); i++) + PTRACE(3, "RTP\tOnSourceDescription: " << description[i]); #endif } -void RTP_Session::OnRxGoodbye(const PDWORDArray & PTRACE_src, const PString & PTRACE_reason) +void RTP_Session::OnRxGoodbye(const PDWORDArray & PTRACE_PARAM(src), const PString & PTRACE_PARAM(reason)) { - PTRACE(3, "RTP\tOnGoodbye: \"" << PTRACE_reason << "\" srcs=" << PTRACE_src); + PTRACE(3, "RTP\tOnGoodbye: \"" << reason << "\" srcs=" << src); } -void RTP_Session::OnRxApplDefined(const PString & PTRACE_type, - unsigned PTRACE_subtype, DWORD PTRACE_src, - const BYTE * /*data*/, PINDEX PTRACE_size) +void RTP_Session::OnRxApplDefined(const PString & PTRACE_PARAM(type), + unsigned PTRACE_PARAM(subtype), DWORD PTRACE_PARAM(src), + const BYTE * /*data*/, PINDEX PTRACE_PARAM(size)) { - PTRACE(3, "RTP\tOnApplDefined: \"" << PTRACE_type << "\"-" << PTRACE_subtype - << " " << PTRACE_src << " [" << PTRACE_size << ']'); + PTRACE(3, "RTP\tOnApplDefined: \"" << type << "\"-" << subtype + << " " << src << " [" << size << ']'); } -- 2.11.4.GIT