Return-Path: Delivered-To: apmail-ws-axis-dev-archive@www.apache.org Received: (qmail 1939 invoked from network); 9 Sep 2003 12:53:32 -0000 Received: from daedalus.apache.org (HELO mail.apache.org) (208.185.179.12) by minotaur-2.apache.org with SMTP; 9 Sep 2003 12:53:32 -0000 Received: (qmail 4611 invoked by uid 500); 9 Sep 2003 12:53:04 -0000 Delivered-To: apmail-ws-axis-dev-archive@ws.apache.org Received: (qmail 4577 invoked by uid 500); 9 Sep 2003 12:53:03 -0000 Mailing-List: contact axis-dev-help@ws.apache.org; run by ezmlm Precedence: bulk Reply-To: axis-dev@ws.apache.org list-help: list-unsubscribe: list-post: Delivered-To: mailing list axis-dev@ws.apache.org Received: (qmail 4529 invoked by uid 500); 9 Sep 2003 12:53:03 -0000 Delivered-To: apmail-xml-axis-cvs@apache.org Date: 9 Sep 2003 12:53:01 -0000 Message-ID: <20030909125301.1684.qmail@minotaur.apache.org> From: susantha@apache.org To: xml-axis-cvs@apache.org Subject: cvs commit: xml-axis/c/src/wsdd WSDDDeployment.cpp WSDDDocument.cpp WSDDKeywords.cpp WSDDService.cpp WSDDTransport.cpp X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N susantha 2003/09/09 05:53:01 Modified: c/src/common AxisException.cpp AxisException.h AxisTime.cpp AxisUtils.cpp AxisUtils.h BasicTypeSerializer.cpp IParam.h Param.cpp TypeMapping.cpp TypeMapping.h c/src/engine Axis.cpp AxisEngine.cpp HandlerChain.cpp HandlerLoader.cpp HandlerPool.cpp c/src/server/handlers/custom/loghandler LogHandler.cpp c/src/server/handlers/custom/simpleauthhandler SimpleAuthorizationHandler.cpp c/src/server/handlers/global/testhandler1 TestGlobal.cpp c/src/server/handlers/transport/testhandler2 TestTransport.cpp c/src/soap SoapSerializer.cpp URIMapping.cpp URIMapping.h XMLStreamHandler.cpp c/src/wsdd WSDDDeployment.cpp WSDDDocument.cpp WSDDKeywords.cpp WSDDService.cpp WSDDTransport.cpp Log: Did following changes and fixes 1. Fixed a bug in Param class's copy constructor. 2. Improved AxisUtils class and changed codebase accordingly. 3. Removed the use of iostream, fstream etc as they may conflict with some flavours of STL 4. Removed the use of AxisTrace (temporarily). Revision Changes Path 1.6 +5 -2 xml-axis/c/src/common/AxisException.cpp Index: AxisException.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/common/AxisException.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- AxisException.cpp 4 Sep 2003 06:51:39 -0000 1.5 +++ AxisException.cpp 9 Sep 2003 12:53:00 -0000 1.6 @@ -61,6 +61,9 @@ #include "AxisException.h" +#include +using namespace std; + AxisException::AxisException(int exceptionCode) { processException(exceptionCode); @@ -94,14 +97,14 @@ string AxisException::getMessage(exception* e) { string sMessage; - exception *objType = static_cast (e); + exception *objType = static_cast (e); if(objType != NULL) { //cout << "bad_alloc" << endl; sMessage = "thrown by new"; } - objType = static_cast (e); + objType = static_cast (e); if(objType != NULL) { //cout << "bad_cast" << endl; 1.7 +0 -1 xml-axis/c/src/common/AxisException.h Index: AxisException.h =================================================================== RCS file: /home/cvs/xml-axis/c/src/common/AxisException.h,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- AxisException.h 4 Sep 2003 06:51:39 -0000 1.6 +++ AxisException.h 9 Sep 2003 12:53:00 -0000 1.7 @@ -60,7 +60,6 @@ */ #include -#include #include #include "../soap/SoapFaults.h" using namespace std; 1.5 +2 -0 xml-axis/c/src/common/AxisTime.cpp Index: AxisTime.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/common/AxisTime.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- AxisTime.cpp 5 Sep 2003 10:48:50 -0000 1.4 +++ AxisTime.cpp 9 Sep 2003 12:53:00 -0000 1.5 @@ -58,6 +58,8 @@ * @author Damitha Kumarage (damitha@opensource.lk, damitha@jkcsworld.com) * */ +#include + #include "AxisTime.h" #include "AxisUtils.h" 1.4 +11 -1 xml-axis/c/src/common/AxisUtils.cpp Index: AxisUtils.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/common/AxisUtils.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- AxisUtils.cpp 5 Sep 2003 10:48:50 -0000 1.3 +++ AxisUtils.cpp 9 Sep 2003 12:53:00 -0000 1.4 @@ -73,7 +73,7 @@ const AxisXMLCh* AxisUtils::m_strLeftSqBracket = NULL; const AxisXMLCh* AxisUtils::m_strRightSqBracket = NULL; const AxisXMLCh* AxisUtils::m_strColon = NULL; - +AxisXMLCh AxisUtils::m_Buffer[CONVERT_BUFFER_SIZE]; ////////////////////////////////////////////////////////////////////// // Construction/Destruction @@ -101,3 +101,13 @@ m_strRightSqBracket = ToAxisXMLCh("]"); m_strColon = ToAxisXMLCh(":"); } + +//following functions is not thread safe and should only be used +//for initialization purposes. +const AxisXMLCh* AxisUtils::Convert(const AxisChar* pch) +{ + if (XMLString::transcode(pch, m_Buffer, CONVERT_BUFFER_SIZE)) + return m_Buffer; + return NULL; +} + 1.4 +7 -0 xml-axis/c/src/common/AxisUtils.h Index: AxisUtils.h =================================================================== RCS file: /home/cvs/xml-axis/c/src/common/AxisUtils.h,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- AxisUtils.h 5 Sep 2003 10:48:50 -0000 1.3 +++ AxisUtils.h 9 Sep 2003 12:53:00 -0000 1.4 @@ -70,8 +70,12 @@ #include using namespace std; +#define CONVERT_BUFFER_SIZE 1024 + class AxisUtils { + friend class TypeMapping; + friend class URIMapping; public: static void Initialize(); static AxisXMLCh* ToAxisXMLCh(const AxisChar* pch); @@ -82,6 +86,9 @@ static const AxisXMLCh* m_strLeftSqBracket; static const AxisXMLCh* m_strRightSqBracket; static const AxisXMLCh* m_strColon; +private: + static const AxisXMLCh* Convert(const AxisChar* pch); + static AxisXMLCh m_Buffer[CONVERT_BUFFER_SIZE]; }; #endif // !defined(AFX_AXISUTILS_H__B5175A8C_0210_417D_BA43_6AAAF7E03551__INCLUDED_) 1.12 +1 -0 xml-axis/c/src/common/BasicTypeSerializer.cpp Index: BasicTypeSerializer.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/common/BasicTypeSerializer.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -u -r1.11 -r1.12 --- BasicTypeSerializer.cpp 5 Sep 2003 10:48:50 -0000 1.11 +++ BasicTypeSerializer.cpp 9 Sep 2003 12:53:00 -0000 1.12 @@ -65,6 +65,7 @@ // ////////////////////////////////////////////////////////////////////// +#include #include "BasicTypeSerializer.h" ////////////////////////////////////////////////////////////////////// 1.6 +1 -0 xml-axis/c/src/common/IParam.h Index: IParam.h =================================================================== RCS file: /home/cvs/xml-axis/c/src/common/IParam.h,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- IParam.h 1 Sep 2003 13:43:31 -0000 1.5 +++ IParam.h 9 Sep 2003 12:53:00 -0000 1.6 @@ -94,6 +94,7 @@ AxisString m_URI; public: ComplexObjectHandler(); + ~ComplexObjectHandler(); void Init(); }; 1.15 +15 -11 xml-axis/c/src/common/Param.cpp Index: Param.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/common/Param.cpp,v retrieving revision 1.14 retrieving revision 1.15 diff -u -r1.14 -r1.15 --- Param.cpp 5 Sep 2003 10:48:50 -0000 1.14 +++ Param.cpp 9 Sep 2003 12:53:00 -0000 1.15 @@ -69,7 +69,7 @@ #include "ArrayBean.h" #include "BasicTypeSerializer.h" #include - +#include #include "AxisUtils.h" ////////////////////////////////////////////////////////////////////// @@ -78,27 +78,27 @@ Param::Param(const Param& param) { - m_sName = param.m_sName; - m_sValue = param.m_sValue; + m_sName = param.m_sName.c_str(); + m_sValue = param.m_sValue.c_str(); m_Type = param.m_Type; if (m_Type == USER_TYPE) { - m_Value.pCplxObj = new ComplexObjectHandler; - m_Value.pCplxObj->m_TypeName = param.m_Value.pCplxObj->m_TypeName; - m_Value.pCplxObj->m_URI = param.m_Value.pCplxObj->m_URI; + m_Value.pCplxObj = new ComplexObjectHandler(); + m_Value.pCplxObj->m_TypeName = param.m_Value.pCplxObj->m_TypeName.c_str(); + m_Value.pCplxObj->m_URI = param.m_Value.pCplxObj->m_URI.c_str(); } else if(m_Type == XSD_ARRAY) { m_Value.pArray = new ArrayBean(); - m_Value.pArray->m_TypeName = param.m_Value.pArray->m_TypeName; - m_Value.pArray->m_URI = param.m_Value.pArray->m_URI; + m_Value.pArray->m_TypeName = param.m_Value.pArray->m_TypeName.c_str(); + m_Value.pArray->m_URI = param.m_Value.pArray->m_URI.c_str(); m_Value.pArray->m_type = param.m_Value.pArray->m_type; m_Value.pArray->m_size = param.m_Value.pArray->m_size; - m_Value.pArray->m_ItemName = param.m_Value.pArray->m_ItemName; + m_Value.pArray->m_ItemName = param.m_Value.pArray->m_ItemName.c_str(); //copy constructor is not intended to use to copy the array in //union v } - if (m_Type == XSD_DURATION || m_Type == XSD_DATETIME) + else if (m_Type == XSD_DURATION || m_Type == XSD_DATETIME) { m_uAxisTime.setType(m_Type); } @@ -234,7 +234,6 @@ if (m_Value.pArray) delete m_Value.pArray; break; case USER_TYPE: - if (m_Value.pCplxObj->pObject) m_Value.pCplxObj->pDelFunct(m_Value.pCplxObj->pObject); delete m_Value.pCplxObj; break; default:; @@ -954,6 +953,11 @@ ComplexObjectHandler::ComplexObjectHandler() { Init(); +} + +ComplexObjectHandler::~ComplexObjectHandler() +{ + if (pObject && pDelFunct) pDelFunct(pObject); } void ComplexObjectHandler::Init() 1.6 +2 -2 xml-axis/c/src/common/TypeMapping.cpp Index: TypeMapping.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/common/TypeMapping.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- TypeMapping.cpp 5 Sep 2003 10:48:50 -0000 1.5 +++ TypeMapping.cpp 9 Sep 2003 12:53:00 -0000 1.6 @@ -67,12 +67,12 @@ #include "TypeMapping.h" #include "AxisUtils.h" -#define __TRC(X) AxisUtils::ToAxisXMLCh(X) +#define __TRC(X) AxisUtils::Convert(X) ////////////////////////////////////////////////////////////////////// // Construction/Destruction ////////////////////////////////////////////////////////////////////// -map TypeMapping::m_sTypeMap; +map TypeMapping::m_sTypeMap; volatile bool TypeMapping::m_bInit = false; TypeMapping::TypeMapping() 1.6 +1 -1 xml-axis/c/src/common/TypeMapping.h Index: TypeMapping.h =================================================================== RCS file: /home/cvs/xml-axis/c/src/common/TypeMapping.h,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- TypeMapping.h 5 Sep 2003 10:48:50 -0000 1.5 +++ TypeMapping.h 9 Sep 2003 12:53:00 -0000 1.6 @@ -86,7 +86,7 @@ public: static XSDTYPE Map(const AxisXMLCh* sType); static void Initialize(); - static map m_sTypeMap; + static map m_sTypeMap; static volatile bool m_bInit; TypeMapping(); virtual ~TypeMapping(); 1.16 +9 -7 xml-axis/c/src/engine/Axis.cpp Index: Axis.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/engine/Axis.cpp,v retrieving revision 1.15 retrieving revision 1.16 diff -u -r1.15 -r1.16 --- Axis.cpp 5 Sep 2003 10:48:50 -0000 1.15 +++ Axis.cpp 9 Sep 2003 12:53:01 -0000 1.16 @@ -68,7 +68,7 @@ #endif #include "AxisEngine.h" -#include "../common/AxisTrace.h" +//#include "../common/AxisTrace.h" #include #include #include @@ -123,9 +123,11 @@ //un synchronized read-only global variables. WSDDDeployment* g_pWSDDDeployment; +#define AXISTRACE1 + extern "C" int process_request(Ax_soapstream *str) { - AXISTRACE1("in axis.cpp"); +// AXISTRACE1("in axis.cpp"); int Status = FAIL; FILE * WsddFile; char ReadBuffer[BYTESTOREAD]; @@ -141,13 +143,13 @@ //Handle the POST method if (str->so.http.ip_method == AXIS_HTTP_POST) { - AXISTRACE1("method is POST"); +// AXISTRACE1("method is POST"); AxisEngine* engine = new AxisEngine(); if (engine) { Status = engine->Process(str); - AXISTRACE1("Status = engine->Process(str);"); - AXISTRACE1("are we successful?"); +// AXISTRACE1("Status = engine->Process(str);"); +// AXISTRACE1("are we successful?"); Status = SUCCESS; delete engine; } @@ -184,7 +186,7 @@ for (iter = pSrvMap->begin();iter != pSrvMap->end();iter++) { - pService = iter->second; + pService = (*iter).second; send_response_bytes("", str->str.op_stream); send_response_bytes((char *)pService->GetServiceName(), str->str.op_stream); send_response_bytes("str.op_stream); @@ -232,7 +234,7 @@ extern "C" int initialize_module() { //order of these initialization method invocation should not be changed - AXISTRACE1("inside initialize_module\n"); +// AXISTRACE1("inside initialize_module\n"); XMLPlatformUtils::Initialize(); AxisUtils::Initialize(); WSDDKeywords::Initialize(); 1.21 +11 -11 xml-axis/c/src/engine/AxisEngine.cpp Index: AxisEngine.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/engine/AxisEngine.cpp,v retrieving revision 1.20 retrieving revision 1.21 diff -u -r1.20 -r1.21 --- AxisEngine.cpp 5 Sep 2003 10:48:50 -0000 1.20 +++ AxisEngine.cpp 9 Sep 2003 12:53:01 -0000 1.21 @@ -64,7 +64,7 @@ #include #include "AxisEngine.h" #include "../common/AxisException.h" -#include "../common/AxisTrace.h" +//#include "../common/AxisTrace.h" #include "../common/Packet.h" #include "../common/AxisUtils.h" #include "../wsdd/WSDDDeployment.h" @@ -100,7 +100,7 @@ { int Status; AXIS_TRY - AXISTRACE1("AxisEngine::Process"); +// AXISTRACE1("AxisEngine::Process"); MessageData* pMsg = NULL; const WSDDService* pService = NULL; string sSessionId = soap->sessionid; @@ -138,7 +138,7 @@ AxisString service = (cService == NULL)? "" : cService; //AxisUtils::convert(service, (cService == NULL)? "" : cService); - AXISTRACE2("string service = ",service.c_str()); +// AXISTRACE2("string service = ",service.c_str()); if (service.empty()) { @@ -188,7 +188,7 @@ if (pSm) { const AxisChar* pMethod = pSm->getMethodName(); - AXISTRACE2("pSm->getMethodName(); :", pMethod); +// AXISTRACE2("pSm->getMethodName(); :", pMethod); if (pMethod) { if (pService->IsAllowedMethod(pMethod)) @@ -260,7 +260,7 @@ in a logfile specific to axis. */ #ifdef _AXISTRACE - AXISTRACE1(e->what()); +// AXISTRACE1(e->what()); delete(e); #endif AXIS_CATCH(...) @@ -271,7 +271,7 @@ from the webserver and report the error. You can also write this in a logfile specific to axis. */ - AXISTRACE1("UNKNOWN EXCEPTION"); +// AXISTRACE1("UNKNOWN EXCEPTION"); AXIS_ENDCATCH return Status; } @@ -292,7 +292,7 @@ } } - AXISTRACE1("AFTER invoke transport request handlers"); +// AXISTRACE1("AFTER invoke transport request handlers"); level++; // AE_TRH //invoke global request handlers if (m_pGReqFChain) @@ -303,7 +303,7 @@ break; //do .. while (0) } } - AXISTRACE1("AFTER invoke global request handlers"); +// AXISTRACE1("AFTER invoke global request handlers"); level++; //AE_GLH //invoke service specific request handlers if (m_pSReqFChain) @@ -314,7 +314,7 @@ break; //do .. while (0) } } - AXISTRACE1("AFTER invoke service specific request handlers"); +// AXISTRACE1("AFTER invoke service specific request handlers"); level++; //AE_SERH //call actual web service handler if (m_pWebService) @@ -325,7 +325,7 @@ break; } } - AXISTRACE1("AFTER call actual web service handler"); +// AXISTRACE1("AFTER call actual web service handler"); level++; //AE_SERV } while(0); @@ -359,7 +359,7 @@ //no break; case AE_START:;//transport handlers have failed }; - AXISTRACE1("end axisengine process()"); +// AXISTRACE1("end axisengine process()"); return Status; } 1.7 +3 -3 xml-axis/c/src/engine/HandlerChain.cpp Index: HandlerChain.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/engine/HandlerChain.cpp,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- HandlerChain.cpp 4 Sep 2003 06:51:40 -0000 1.6 +++ HandlerChain.cpp 9 Sep 2003 12:53:01 -0000 1.7 @@ -66,7 +66,7 @@ ////////////////////////////////////////////////////////////////////// #include "HandlerChain.h" -#include "../common/AxisTrace.h" +//#include "../common/AxisTrace.h" ////////////////////////////////////////////////////////////////////// // Construction/Destruction @@ -84,7 +84,7 @@ int HandlerChain::Invoke(IMessageData* pMsg) { - AXISTRACE1("HandlerChain::Invoke(IMessageData* pMsg)"); +// AXISTRACE1("HandlerChain::Invoke(IMessageData* pMsg)"); m_itCurrHandler = m_HandlerList.begin(); while (m_itCurrHandler != m_HandlerList.end()) { @@ -98,7 +98,7 @@ return FAIL; } } - AXISTRACE1("HandlerChain::Invoke end"); +// AXISTRACE1("HandlerChain::Invoke end"); return SUCCESS; } 1.11 +4 -4 xml-axis/c/src/engine/HandlerLoader.cpp Index: HandlerLoader.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/engine/HandlerLoader.cpp,v retrieving revision 1.10 retrieving revision 1.11 diff -u -r1.10 -r1.11 --- HandlerLoader.cpp 5 Sep 2003 10:48:50 -0000 1.10 +++ HandlerLoader.cpp 9 Sep 2003 12:53:01 -0000 1.11 @@ -63,7 +63,7 @@ #include "HandlerLoader.h" #include -#include "../common/AxisTrace.h" +//#include "../common/AxisTrace.h" #include "../common/AxisUtils.h" #include "../wsdd/WSDDDeployment.h" @@ -108,12 +108,12 @@ int HandlerLoader::LoadLib(HandlerInformation* pHandlerInfo) { - AXISTRACE2("in HandlerLoader::LoadLib(), Lib is :", pHandlerInfo->m_sLib.c_str()); +// AXISTRACE2("in HandlerLoader::LoadLib(), Lib is :", pHandlerInfo->m_sLib.c_str()); #ifdef WIN32 pHandlerInfo->m_Handler = LoadLibrary(pHandlerInfo->m_sLib.c_str()); #else //Linux pHandlerInfo->m_Handler = dlopen(pHandlerInfo->m_sLib.c_str(), pHandlerInfo->m_nLoadOptions); - AXISTRACE1("after m_Handler = dlopen(pHandlerInfo->m_sLib.c_str(), pHandlerInfo->m_nLoadOptions);"); +// AXISTRACE1("after m_Handler = dlopen(pHandlerInfo->m_sLib.c_str(), pHandlerInfo->m_nLoadOptions);"); #endif return (pHandlerInfo->m_Handler != 0)?SUCCESS:FAIL; } @@ -130,7 +130,7 @@ int HandlerLoader::CreateHandler(BasicHandler** pHandler, int nLibId) { - AXISTRACE1("inside CreateHandler\n"); +// AXISTRACE1("inside CreateHandler\n"); lock(); *pHandler = NULL; HandlerInformation* pHandlerInfo = NULL; 1.11 +1 -1 xml-axis/c/src/engine/HandlerPool.cpp Index: HandlerPool.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/engine/HandlerPool.cpp,v retrieving revision 1.10 retrieving revision 1.11 diff -u -r1.10 -r1.11 --- HandlerPool.cpp 4 Sep 2003 06:51:40 -0000 1.10 +++ HandlerPool.cpp 9 Sep 2003 12:53:01 -0000 1.11 @@ -73,7 +73,7 @@ ////////////////////////////////////////////////////////////////////// // Construction/Destruction ////////////////////////////////////////////////////////////////////// -#include "../common/AxisTrace.h" +//#include "../common/AxisTrace.h" extern AppScopeHandlerPool* g_pAppScopeHandlerPool; extern RequestScopeHandlerPool* g_pRequestScopeHandlerPool; 1.5 +4 -4 xml-axis/c/src/server/handlers/custom/loghandler/LogHandler.cpp Index: LogHandler.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/server/handlers/custom/loghandler/LogHandler.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- LogHandler.cpp 4 Sep 2003 06:51:40 -0000 1.4 +++ LogHandler.cpp 9 Sep 2003 12:53:01 -0000 1.5 @@ -64,7 +64,7 @@ #include "../../../../soap/SoapSerializer.h" #include #include -#include "../../../../common/AxisTrace.h" +//#include "../../../../common/AxisTrace.h" using namespace std; @@ -84,7 +84,7 @@ int LogHandler::Invoke(IMessageData* md) { AXIS_TRY - AXISTRACE1("LogHandler::Invoke(IMessageData* md)"); +// AXISTRACE1("LogHandler::Invoke(IMessageData* md)"); m_iNumAccess = 0; string sNumAccess = ""; @@ -94,7 +94,7 @@ if(!sFileName.empty()) { - AXISTRACE1("if(!sFileName.empty())"); +// AXISTRACE1("if(!sFileName.empty())"); ifstream fin(sFileName.c_str()); // open for reading char ch; @@ -120,7 +120,7 @@ const char * FileName = sFileName.c_str(); ofstream fout(FileName); // open for writing fout << m_iNumAccess; - AXISTRACE1("LogHandler Invoke end"); +// AXISTRACE1("LogHandler Invoke end"); fin.close(); fout.close(); return SUCCESS; 1.4 +4 -4 xml-axis/c/src/server/handlers/custom/simpleauthhandler/SimpleAuthorizationHandler.cpp Index: SimpleAuthorizationHandler.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/server/handlers/custom/simpleauthhandler/SimpleAuthorizationHandler.cpp,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- SimpleAuthorizationHandler.cpp 4 Sep 2003 06:51:40 -0000 1.3 +++ SimpleAuthorizationHandler.cpp 9 Sep 2003 12:53:01 -0000 1.4 @@ -65,7 +65,7 @@ #include #include #include -#include "../../../../common/AxisTrace.h" +//#include "../../../../common/AxisTrace.h" #include "../../../../common/MessageData.h" SimpleAuthorizationHandler::SimpleAuthorizationHandler() @@ -82,7 +82,7 @@ { try { - AXISTRACE1("SimpleAuthorizationHandler::Invoke(IMessageData* md)"); +// AXISTRACE1("SimpleAuthorizationHandler::Invoke(IMessageData* md)"); string sValue = GetOption("AllowByDefault"); AXISTRACE2("sValue :", sValue); int intIsAllowed = atoi(sValue.c_str()); @@ -113,12 +113,12 @@ AXISTRACE2("(*m_itCurrentRole).c_str()", (*m_itCurrentRole).c_str()); if(strcmp(m_sAuthUser.c_str(),(*m_itCurrentRole).c_str()) == 0) { - AXISTRACE1("if(strcmp(m_sAuthUser.c_str(),(*m_itCurrentRole).c_str()) == 0)"); +// AXISTRACE1("if(strcmp(m_sAuthUser.c_str(),(*m_itCurrentRole).c_str()) == 0)"); return SUCCESS; } m_itCurrentRole++; } - AXISTRACE1("SimpleAuthorizationHandler invoke end"); +// AXISTRACE1("SimpleAuthorizationHandler invoke end"); fin.close(); } else 1.6 +3 -3 xml-axis/c/src/server/handlers/global/testhandler1/TestGlobal.cpp Index: TestGlobal.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/server/handlers/global/testhandler1/TestGlobal.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- TestGlobal.cpp 4 Sep 2003 06:51:40 -0000 1.5 +++ TestGlobal.cpp 9 Sep 2003 12:53:01 -0000 1.6 @@ -63,7 +63,7 @@ #include "TestGlobal.h" #include //#include -#include "../../../../common/AxisTrace.h" +//#include "../../../../common/AxisTrace.h" #include "../../../../common/AxisException.h" //using namespace std; @@ -85,12 +85,12 @@ { AXIS_TRY - AXISTRACE1("Hi, you successfully invoked TestGlobal handler"); +// AXISTRACE1("Hi, you successfully invoked TestGlobal handler"); return SUCCESS; AXIS_CATCH(...) - AXISTRACE1("inside catch block"); +// AXISTRACE1("inside catch block"); return FAIL; AXIS_ENDCATCH 1.5 +2 -2 xml-axis/c/src/server/handlers/transport/testhandler2/TestTransport.cpp Index: TestTransport.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/server/handlers/transport/testhandler2/TestTransport.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- TestTransport.cpp 4 Sep 2003 06:51:41 -0000 1.4 +++ TestTransport.cpp 9 Sep 2003 12:53:01 -0000 1.5 @@ -65,7 +65,7 @@ #include "../../../../soap/SoapSerializer.h" #include #include -#include "../../../../common/AxisTrace.h" +//#include "../../../../common/AxisTrace.h" using namespace std; @@ -85,7 +85,7 @@ int TestTransport::Invoke(IMessageData* md) { AXIS_TRY - AXISTRACE1("Hi, you have successfully invoked the TestTransport handler"); +// AXISTRACE1("Hi, you have successfully invoked the TestTransport handler"); return SUCCESS; AXIS_CATCH(...) return FAIL; 1.19 +1 -0 xml-axis/c/src/soap/SoapSerializer.cpp Index: SoapSerializer.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/soap/SoapSerializer.cpp,v retrieving revision 1.18 retrieving revision 1.19 diff -u -r1.18 -r1.19 --- SoapSerializer.cpp 5 Sep 2003 10:48:51 -0000 1.18 +++ SoapSerializer.cpp 9 Sep 2003 12:53:01 -0000 1.19 @@ -75,6 +75,7 @@ #include "../common/ArrayBean.h" #include "../common/BasicTypeSerializer.h" #include "SoapKeywordMapping.h" +#include extern "C" int sendSoapResponse(char *cSerializedStream); 1.5 +1 -10 xml-axis/c/src/soap/URIMapping.cpp Index: URIMapping.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/soap/URIMapping.cpp,v retrieving revision 1.4 retrieving revision 1.5 diff -u -r1.4 -r1.5 --- URIMapping.cpp 5 Sep 2003 10:48:51 -0000 1.4 +++ URIMapping.cpp 9 Sep 2003 12:53:01 -0000 1.5 @@ -67,7 +67,7 @@ #include "URIMapping.h" #include "../common/AxisUtils.h" -#define __TRC(X) AxisUtils::ToAxisXMLCh(X) +#define __TRC(X) AxisUtils::Convert(X) ////////////////////////////////////////////////////////////////////// // Construction/Destruction ////////////////////////////////////////////////////////////////////// @@ -94,15 +94,6 @@ m_sURIMap[__TRC("http://schemas.xmlsoap.org/soap/envelope/")] = URI_ENVELOPE; m_bInit = true; } -} - -URITYPE URIMapping::Map(const AxisXMLString &uri) -{ - if (m_sURIMap.find(uri) != m_sURIMap.end()) - { - return m_sURIMap[uri]; - } - return URI_UNKNOWN; } URITYPE URIMapping::Map(const AxisXMLCh* uri) 1.6 +0 -1 xml-axis/c/src/soap/URIMapping.h Index: URIMapping.h =================================================================== RCS file: /home/cvs/xml-axis/c/src/soap/URIMapping.h,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- URIMapping.h 5 Sep 2003 10:48:51 -0000 1.5 +++ URIMapping.h 9 Sep 2003 12:53:01 -0000 1.6 @@ -83,7 +83,6 @@ static volatile bool m_bInit; URIMapping(); virtual ~URIMapping(); - static URITYPE Map(const AxisXMLString &uri); static URITYPE Map(const AxisXMLCh* uri); }; 1.12 +10 -10 xml-axis/c/src/soap/XMLStreamHandler.cpp Index: XMLStreamHandler.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/soap/XMLStreamHandler.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -u -r1.11 -r1.12 --- XMLStreamHandler.cpp 5 Sep 2003 10:48:51 -0000 1.11 +++ XMLStreamHandler.cpp 9 Sep 2003 12:53:01 -0000 1.12 @@ -161,7 +161,7 @@ case SOAP_UNKNOWN: if (XMLString::equals(localname,SoapKeywordMapping::Map(m_nSoapVersion).pchWords[SKW_MULTIREF])) { - m_sLastElement = (wchar_t*) localname; + m_sLastElement = localname; SetParamType(attrs); m_PL1 = SOAP_PARAM; } @@ -175,18 +175,18 @@ case SOAP_METHOD: //now comes parameters //Get Param name and type //m_Param.m_sName = localname; - m_sLastElement = (wchar_t*) localname; + m_sLastElement = localname; SetParamType(attrs); m_PL1 = SOAP_PARAM; m_nParamNestingLevel++; break; case SOAP_PARAM: //Custom types - if (m_sLastElement != (wchar_t*) localname) + if (!(m_sLastElement == localname)) { m_Params.push_back(new Param(m_Param)); //parent param } //m_Param.m_sName = localname; - m_sLastElement = (wchar_t*) localname; + m_sLastElement = localname; SetParamType(attrs); m_nParamNestingLevel++; break; @@ -215,7 +215,7 @@ break; case SOAP_PARAM: //end of a parameter //Add parameter to list - if (m_sLastElement == (wchar_t*) localname) + if (m_sLastElement == localname) { m_Params.push_back(new Param(m_Param)); //current param } @@ -284,12 +284,12 @@ void XMLStreamHandler::startPrefixMapping(const XMLCh* const prefix, const XMLCh* const uri) { - m_NsStack[(wchar_t*) prefix] = (wchar_t*) uri; //I think the same prifix cannot repeat ??? + m_NsStack[prefix] = uri; //I think the same prifix cannot repeat ??? } void XMLStreamHandler::endPrefixMapping(const XMLCh* const prefix) { - m_NsStack.erase((wchar_t*) prefix); //I think the same prifix cannot repeat ??? + m_NsStack.erase(prefix); //I think the same prifix cannot repeat ??? } void XMLStreamHandler::warning(const SAXParseException& exception) @@ -335,7 +335,7 @@ sType = sValue.substr(colonindex+1,AxisXMLString::npos); if (m_NsStack.find(sPrefix) != m_NsStack.end()) { - if(URIMapping::Map(m_NsStack[sPrefix]) == URI_XSD) + if(URIMapping::Map(m_NsStack[sPrefix].c_str()) == URI_XSD) { //check for xml data types m_Param.m_Type = TypeMapping::Map(sType.c_str()); @@ -384,7 +384,7 @@ if (m_NsStack.find(sPrefix) != m_NsStack.end()) { - if(URIMapping::Map(m_NsStack[sPrefix]) == URI_XSD) + if(URIMapping::Map(m_NsStack[sPrefix].c_str()) == URI_XSD) { //check for xml data types m_Param.m_Value.pArray->m_type = TypeMapping::Map(sType.c_str()); @@ -500,7 +500,7 @@ { AxisXMLString str; Attribute* pAttr; - str = (wchar_t*) qname; + str = qname; pAttr = new Attribute(); if (str.find(AxisUtils::m_strColon) != AxisXMLString::npos) { 1.10 +1 -1 xml-axis/c/src/wsdd/WSDDDeployment.cpp Index: WSDDDeployment.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/wsdd/WSDDDeployment.cpp,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- WSDDDeployment.cpp 5 Sep 2003 10:48:51 -0000 1.9 +++ WSDDDeployment.cpp 9 Sep 2003 12:53:01 -0000 1.10 @@ -115,7 +115,7 @@ for(iter2=m_DeployedServices->begin() ;iter2!=m_DeployedServices->end();iter2++) { - delete (iter2->second); + delete ((*iter2).second); } } 1.14 +4 -4 xml-axis/c/src/wsdd/WSDDDocument.cpp Index: WSDDDocument.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/wsdd/WSDDDocument.cpp,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- WSDDDocument.cpp 5 Sep 2003 10:48:51 -0000 1.13 +++ WSDDDocument.cpp 9 Sep 2003 12:53:01 -0000 1.14 @@ -65,7 +65,7 @@ #include "WSDDDocument.h" #include "WSDDKeywords.h" #include -#include "../common/AxisTrace.h" +//#include "../common/AxisTrace.h" #define __XTRC(X) (true == XMLString::transcode(X, m_Buffer, TRANSCODE_BUFFER_SIZE-1))? m_Buffer : "" @@ -94,13 +94,13 @@ int WSDDDocument::ParseDocument(const AxisChar* sWSDD) { - AXISTRACE1("inside ParseDocument\n"); +// AXISTRACE1("inside ParseDocument\n"); try { SAX2XMLReader* parser = XMLReaderFactory::createXMLReader(); parser->setContentHandler(this); parser->setErrorHandler(this); - AXISTRACE1("BEFORE parser->parse(sWSDD);"); +// AXISTRACE1("BEFORE parser->parse(sWSDD);"); parser->parse(sWSDD); delete parser; } @@ -518,7 +518,7 @@ void WSDDDocument::endPrefixMapping(const XMLCh* const prefix) { // string sPrifix = prefix; - m_NsStack.erase((wchar_t*) prefix); //I think the same prifix cannot repeat ??? + m_NsStack.erase(prefix); //I think the same prifix cannot repeat ??? } void WSDDDocument::characters (const XMLCh *const chars, const unsigned int length) 1.2 +2 -2 xml-axis/c/src/wsdd/WSDDKeywords.cpp Index: WSDDKeywords.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/wsdd/WSDDKeywords.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -u -r1.1 -r1.2 --- WSDDKeywords.cpp 5 Sep 2003 10:48:51 -0000 1.1 +++ WSDDKeywords.cpp 9 Sep 2003 12:53:01 -0000 1.2 @@ -12,7 +12,7 @@ // Construction/Destruction ////////////////////////////////////////////////////////////////////// -#define DELETE(X) delete const_cast(X) +#define AX_DELETE(X) delete const_cast(X) const AxisXMLCh* kw_depl; const AxisXMLCh* kw_srv; @@ -77,7 +77,7 @@ { if (m_bInit) { - DELETE(kw_smtp); + AX_DELETE(kw_smtp); m_bInit = false; } } 1.9 +1 -1 xml-axis/c/src/wsdd/WSDDService.cpp Index: WSDDService.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/wsdd/WSDDService.cpp,v retrieving revision 1.8 retrieving revision 1.9 diff -u -r1.8 -r1.9 --- WSDDService.cpp 5 Sep 2003 10:48:51 -0000 1.8 +++ WSDDService.cpp 9 Sep 2003 12:53:01 -0000 1.9 @@ -66,7 +66,7 @@ ////////////////////////////////////////////////////////////////////// #include "WSDDService.h" -#include "../common/AxisTrace.h" +//#include "../common/AxisTrace.h" ////////////////////////////////////////////////////////////////////// // Construction/Destruction 1.3 +2 -2 xml-axis/c/src/wsdd/WSDDTransport.cpp Index: WSDDTransport.cpp =================================================================== RCS file: /home/cvs/xml-axis/c/src/wsdd/WSDDTransport.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- WSDDTransport.cpp 13 Aug 2003 13:31:42 -0000 1.2 +++ WSDDTransport.cpp 9 Sep 2003 12:53:01 -0000 1.3 @@ -86,7 +86,7 @@ { for(iter = m_RequestHandlers->begin(); iter != m_RequestHandlers->end(); iter++) { - for(iter2 = iter->second.begin(); iter2 != iter->second.end(); iter2++) + for(iter2 = (*iter).second.begin(); iter2 != (*iter).second.end(); iter2++) { delete (*iter2); } @@ -97,7 +97,7 @@ { for(iter = m_ResponseHandlers->begin(); iter != m_ResponseHandlers->end(); iter++) { - for(iter2 = iter->second.begin(); iter2 != iter->second.end();iter2++) + for(iter2 = (*iter).second.begin(); iter2 != (*iter).second.end();iter2++) { delete (*iter2); }