diff options
Diffstat (limited to 'automation/source/simplecm')
-rw-r--r-- | automation/source/simplecm/communiio.hxx | 16 | ||||
-rw-r--r-- | automation/source/simplecm/packethandler.cxx | 46 | ||||
-rw-r--r-- | automation/source/simplecm/packethandler.hxx | 10 | ||||
-rw-r--r-- | automation/source/simplecm/simplecm.cxx | 26 |
4 files changed, 49 insertions, 49 deletions
diff --git a/automation/source/simplecm/communiio.hxx b/automation/source/simplecm/communiio.hxx index c0625ed8b2c6..e5c623f6ebb8 100644 --- a/automation/source/simplecm/communiio.hxx +++ b/automation/source/simplecm/communiio.hxx @@ -2,7 +2,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -28,18 +28,18 @@ /************************************************************************* * - * ATTENTION - * This file is intended to work inside and outside the StarOffice environment. - * Only adaption of file commtypes.hxx should be necessary. Else it is a bug! + * ATTENTION + * This file is intended to work inside and outside the StarOffice environment. + * Only adaption of file commtypes.hxx should be necessary. Else it is a bug! * ************************************************************************/ #include <automation/commtypes.hxx> -#define C_ERROR_NONE 0x0001 -#define C_ERROR_PERMANENT 0x0002 -#define C_ERROR_RETRY 0x0003 -#define C_ERROR_TIMEOUT 0x0004 +#define C_ERROR_NONE 0x0001 +#define C_ERROR_PERMANENT 0x0002 +#define C_ERROR_RETRY 0x0003 +#define C_ERROR_TIMEOUT 0x0004 class ITransmiter { diff --git a/automation/source/simplecm/packethandler.cxx b/automation/source/simplecm/packethandler.cxx index 034143d2cba6..3f0e4125372c 100644 --- a/automation/source/simplecm/packethandler.cxx +++ b/automation/source/simplecm/packethandler.cxx @@ -2,7 +2,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -31,9 +31,9 @@ /************************************************************************* * - * ATTENTION - * This file is intended to work inside and outside the StarOffice environment. - * Only adaption of file commtypes.hxx should be necessary. Else it is a bug! + * ATTENTION + * This file is intended to work inside and outside the StarOffice environment. + * Only adaption of file commtypes.hxx should be necessary. Else it is a bug! * ************************************************************************/ @@ -98,7 +98,7 @@ comm_BOOL PacketHandler::ReceiveData( void* &pData, comm_UINT32 &nLen ) if ( bWasError ) return FALSE; - if ( 0xFFFFFFFF == nBytes ) // Expliziter Request für dieses Datenpaket auf MultiChannel umzuschalten + if ( 0xFFFFFFFF == nBytes ) // Expliziter Request für dieses Datenpaket auf MultiChannel umzuschalten { READ_SOCKET( &nBytes, sizeof(nBytes) ) if ( bWasError ) @@ -210,13 +210,13 @@ comm_BOOL PacketHandler::TransferData( const void* pData, comm_UINT32 nLen, CMPr #ifndef FORCE_MULTI_CHANNEL_HEADERS if ( bMultiChannel ) #endif - nBuffer += 1+2+2+2; // für einen CH_SimpleMultiChannel + nBuffer += 1+2+2+2; // für einen CH_SimpleMultiChannel #ifdef FORCE_MULTI_CHANNEL_HEADERS if ( !bMultiChannel ) { comm_UINT32 n32; - n32 = 0xffffffff; // Umschalten auf MultiChannel + n32 = 0xffffffff; // Umschalten auf MultiChannel n32 = NETDWORD( n32 ); WRITE_SOCKET( &n32, 4 ); } @@ -237,11 +237,11 @@ comm_BOOL PacketHandler::TransferData( const void* pData, comm_UINT32 nLen, CMPr c = CalcCheckByte( nBuffer ); WRITE_SOCKET( &c, 1 ); - n16 = 4; // Länge des Headers für einen CH_SimpleMultiChannel + n16 = 4; // Länge des Headers für einen CH_SimpleMultiChannel n16 = NETWORD( n16 ); WRITE_SOCKET( &n16, 2 ); - n16 = CH_SimpleMultiChannel; // Typ des Headers + n16 = CH_SimpleMultiChannel; // Typ des Headers n16 = NETWORD( n16 ); WRITE_SOCKET( &n16, 2 ); @@ -259,40 +259,40 @@ comm_BOOL PacketHandler::SendHandshake( HandshakeType aHandshakeType, const void comm_UINT32 nBuffer = 0; -// if ( pMyManager->IsMultiChannel() ) Wir senden immer FFFFFFFF vorweg -> immer MultiChannel (Oder GPF bei älteren) - nBuffer += 1+2+2; // für einen CH_Handshake +// if ( pMyManager->IsMultiChannel() ) Wir senden immer FFFFFFFF vorweg -> immer MultiChannel (Oder GPF bei älteren) + nBuffer += 1+2+2; // für einen CH_Handshake - nBuffer += 2; // für den Typ des Handshakes + nBuffer += 2; // für den Typ des Handshakes switch ( aHandshakeType ) { case CH_REQUEST_HandshakeAlive: - nBuffer += 0; // Keine extra Daten + nBuffer += 0; // Keine extra Daten break; case CH_RESPONSE_HandshakeAlive: - nBuffer += 0; // Keine extra Daten + nBuffer += 0; // Keine extra Daten break; case CH_REQUEST_ShutdownLink: - nBuffer += 0; // Keine extra Daten + nBuffer += 0; // Keine extra Daten break; case CH_ShutdownLink: - nBuffer += 0; // Keine extra Daten + nBuffer += 0; // Keine extra Daten break; case CH_SUPPORT_OPTIONS: - nBuffer += 2 ; // one word extradata for options + nBuffer += 2 ; // one word extradata for options break; case CH_SetApplication: - nBuffer += 0 ; // one word extradata for options + nBuffer += 0 ; // one word extradata for options break; default: DBG_ERROR("Unknown HandshakeType"); } if ( pData ) - nBuffer += nLen; // Extra data in Buffer + nBuffer += nLen; // Extra data in Buffer comm_UINT32 n32; - n32 = 0xffffffff; // Umschalten auf MultiChannel + n32 = 0xffffffff; // Umschalten auf MultiChannel n32 = NETDWORD( n32 ); WRITE_SOCKET( &n32, 4 ); @@ -306,15 +306,15 @@ comm_BOOL PacketHandler::SendHandshake( HandshakeType aHandshakeType, const void c = CalcCheckByte( nBuffer ); WRITE_SOCKET( &c, 1 ); - n16 = 2; // Länge des Headers für einen CH_Handshake + n16 = 2; // Länge des Headers für einen CH_Handshake n16 = NETWORD( n16 ); WRITE_SOCKET( &n16, 2 ); - n16 = CH_Handshake; // Typ des Headers + n16 = CH_Handshake; // Typ des Headers n16 = NETWORD( n16 ); WRITE_SOCKET( &n16, 2 ); - n16 = aHandshakeType; // Typ des Handshakes + n16 = aHandshakeType; // Typ des Handshakes n16 = NETWORD( n16 ); WRITE_SOCKET( &n16, 2 ); diff --git a/automation/source/simplecm/packethandler.hxx b/automation/source/simplecm/packethandler.hxx index 31081b2e949a..7f42a614b985 100644 --- a/automation/source/simplecm/packethandler.hxx +++ b/automation/source/simplecm/packethandler.hxx @@ -2,7 +2,7 @@ /************************************************************************* * * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * + * * Copyright 2000, 2010 Oracle and/or its affiliates. * * OpenOffice.org - a multi-platform office productivity suite @@ -28,9 +28,9 @@ /************************************************************************* * - * ATTENTION - * This file is intended to work inside and outside the StarOffice environment. - * Only adaption of file commtypes.hxx should be necessary. Else it is a bug! + * ATTENTION + * This file is intended to work inside and outside the StarOffice environment. + * Only adaption of file commtypes.hxx should be necessary. Else it is a bug! * ************************************************************************/ @@ -62,7 +62,7 @@ public: comm_UINT16 GetReceiveProtocol() { return nReceiveProtocol; } comm_UINT16 GetReceiveHeaderType() { return nReceiveHeaderType; } - comm_BOOL ReceiveData( void* &pData, comm_UINT32 &nLen ); /// Recieve DataPacket from Socket + comm_BOOL ReceiveData( void* &pData, comm_UINT32 &nLen ); /// Recieve DataPacket from Socket virtual comm_BOOL SendHandshake( HandshakeType aHandshakeType, const void* pData = NULL, comm_UINT32 nLen = 0 ); virtual comm_BOOL TransferData( const void* pData, comm_UINT32 nLen, CMProtocol nProtocol = CM_PROTOCOL_OLDSTYLE ); }; diff --git a/automation/source/simplecm/simplecm.cxx b/automation/source/simplecm/simplecm.cxx index 26c8d6af0585..ef770100ddca 100644 --- a/automation/source/simplecm/simplecm.cxx +++ b/automation/source/simplecm/simplecm.cxx @@ -168,8 +168,8 @@ void SimpleCommunicationLinkViaSocket::SetStreamSocket( osl::StreamSocket* pSock BOOL SimpleCommunicationLinkViaSocket::StopCommunication() { - CommunicationLinkRef rHold(this); // avoid deleting this link before the end of the method - if ( !IsCommunicationError() ) // Meaning that the Communication is still runnung + CommunicationLinkRef rHold(this); // avoid deleting this link before the end of the method + if ( !IsCommunicationError() ) // Meaning that the Communication is still runnung { #if OSL_DEBUG_LEVEL > 1 debug_printf("Sending REQUEST_ShutdownLink\n"); @@ -250,7 +250,7 @@ ByteString SimpleCommunicationLinkViaSocket::GetMyName( CM_NameType eType ) SvStream* SimpleCommunicationLinkViaSocket::GetBestCommunicationStream() { SvStream* pStream = new SvMemoryStream; -// pStream->SetNumberFormatInt( NUMBERFORMAT_INT_BIGENDIAN ); +// pStream->SetNumberFormatInt( NUMBERFORMAT_INT_BIGENDIAN ); return pStream; } @@ -319,7 +319,7 @@ BOOL SimpleCommunicationLinkViaSocket::SendHandshake( HandshakeType aHandshakeTy ShutdownCommunication(); } else - { // set new status + { // set new status switch ( aHandshakeType ) { case CH_REQUEST_HandshakeAlive: @@ -366,7 +366,7 @@ bool SimpleCommunicationLinkViaSocket::IsReceiveReady() void SimpleCommunicationLinkViaSocketWithReceiveCallbacks::WaitForShutdown() { - CommunicationLinkRef rHold(this); // avoid deleting this link before the end of the method + CommunicationLinkRef rHold(this); // avoid deleting this link before the end of the method while( pMyManager && !IsCommunicationError() && IsReceiveReady()) ReceiveDataStream(); @@ -443,7 +443,7 @@ ByteString CommunicationManager::GetMyName( CM_NameType ) void CommunicationManager::CallConnectionOpened( CommunicationLink* pCL ) { - pCL->StartCallback(); // Sollte bereits vor dem Aufruf gerufen werden + pCL->StartCallback(); // Sollte bereits vor dem Aufruf gerufen werden pCL->aStart = DateTime(); pCL->aLastAccess = pCL->aStart; bIsCommunicationRunning = TRUE; @@ -460,7 +460,7 @@ void CommunicationManager::CallConnectionOpened( CommunicationLink* pCL ) void CommunicationManager::CallConnectionClosed( CommunicationLink* pCL ) { - pCL->StartCallback(); // Sollte bereits vor dem Aufruf gerufen werden + pCL->StartCallback(); // Sollte bereits vor dem Aufruf gerufen werden pCL->aLastAccess = DateTime(); INFO_MSG( CByteString("C-:").Append( pCL->GetCommunicationPartner( CM_FQDN ) ), @@ -472,14 +472,14 @@ void CommunicationManager::CallConnectionClosed( CommunicationLink* pCL ) xLastNewLink.Clear(); pCL->FinishCallback(); -// delete pCL; +// delete pCL; } void CommunicationManager::CallDataReceived( CommunicationLink* pCL ) { - pCL->StartCallback(); // Sollte bereits vor dem Aufruf gerufen werden + pCL->StartCallback(); // Sollte bereits vor dem Aufruf gerufen werden pCL->aLastAccess = DateTime(); - CommunicationLinkRef rHold(pCL); // Hält den Zeiger bis zum Ende des calls + CommunicationLinkRef rHold(pCL); // Hält den Zeiger bis zum Ende des calls // should be impossible but happens for mysterious reasons if ( !pCL->pServiceData ) @@ -494,7 +494,7 @@ void CommunicationManager::CallDataReceived( CommunicationLink* pCL ) { SvStream *pData = pCL->GetServiceData(); USHORT nType; - pData->SetNumberFormatInt( NUMBERFORMAT_INT_BIGENDIAN ); // Unfortulately it is written this way :(( + pData->SetNumberFormatInt( NUMBERFORMAT_INT_BIGENDIAN ); // Unfortulately it is written this way :(( *pData >> nType; pData->SetNumberFormatInt( NUMBERFORMAT_INT_LITTLEENDIAN ); switch ( nType ) @@ -629,7 +629,7 @@ void SingleCommunicationManager::CallConnectionOpened( CommunicationLink* pCL ) if ( pInactiveLink ) pInactiveLink->InvalidateManager(); pInactiveLink = xActiveLink; - xActiveLink->StopCommunication(); // Den alten Link brutal abwürgen + xActiveLink->StopCommunication(); // Den alten Link brutal abwürgen } xActiveLink = pCL; CommunicationManager::CallConnectionOpened( pCL ); @@ -677,7 +677,7 @@ BOOL CommonSocketFunctions::DoStartCommunication( CommunicationManager *pCM, ICo TimeValue aTV; - aTV.Seconds = 10; // Warte 10 Sekunden + aTV.Seconds = 10; // Warte 10 Sekunden aTV.Nanosec = 0; do { |