tng 2003/02/05 10:55:21 Modified: c/tests/DOM/DOMMemTest DOMMemTest.cpp c/tests/DOM/DOMTest DTest.cpp c/tests/DOM/DeprecatedDOMCount DeprecatedDOMCount.hpp c/tests/DOM/RangeTest RangeTest.cpp c/tests/DOM/Traversal Traversal.cpp c/tests/DOM/TypeInfo TypeInfo.cpp c/tests/EncodingTest EncodingTest.cpp c/tests/InitTermTest InitTermTest.cpp InitTermTest.hpp c/tests/ParserTest ParserTest.hpp c/tests/ThreadTest ThreadTest.cpp c/tests/UtilTests CoreTests_RefHashTable.cpp Log: [Bug 11915] Utility for freeing memory. Revision Changes Path 1.42 +3 -3 xml-xerces/c/tests/DOM/DOMMemTest/DOMMemTest.cpp Index: DOMMemTest.cpp =================================================================== RCS file: /home/cvs/xml-xerces/c/tests/DOM/DOMMemTest/DOMMemTest.cpp,v retrieving revision 1.41 retrieving revision 1.42 diff -u -r1.41 -r1.42 --- DOMMemTest.cpp 12 Nov 2002 17:51:48 -0000 1.41 +++ DOMMemTest.cpp 5 Feb 2003 18:55:19 -0000 1.42 @@ -124,7 +124,7 @@ ~XStr() { - delete [] fUnicodeForm; + XMLString::release(&fUnicodeForm); } @@ -1492,7 +1492,7 @@ char *pMessage = XMLString::transcode(toCatch.getMessage()); fprintf(stderr, "Error during XMLPlatformUtils::Initialize(). \n" " Message is: %s\n", pMessage); - delete [] pMessage; + XMLString::release(&pMessage); return -1; } 1.39 +5 -2 xml-xerces/c/tests/DOM/DOMTest/DTest.cpp Index: DTest.cpp =================================================================== RCS file: /home/cvs/xml-xerces/c/tests/DOM/DOMTest/DTest.cpp,v retrieving revision 1.38 retrieving revision 1.39 diff -u -r1.38 -r1.39 --- DTest.cpp 29 Jan 2003 20:04:09 -0000 1.38 +++ DTest.cpp 5 Feb 2003 18:55:19 -0000 1.39 @@ -56,6 +56,9 @@ /* * $Log$ + * Revision 1.39 2003/02/05 18:55:19 tng + * [Bug 11915] Utility for freeing memory. + * * Revision 1.38 2003/01/29 20:04:09 gareth * testing for DOMTypeInfo * @@ -815,7 +818,7 @@ EXCEPTIONSTEST(docBodyLevel32->removeChild(docFirstElement), DOMException::NOT_FOUND_ERR, OK, 15); EXCEPTIONSTEST(docBodyLevel32->replaceChild(docTextNode11,docFirstElement ), DOMException::NOT_FOUND_ERR, OK, 16); - delete [] name; + XMLString::release(&name); return OK; @@ -971,7 +974,7 @@ catch (const XMLException& toCatch) { char *pMessage = XMLString::transcode(toCatch.getMessage()); fprintf(stderr, "Error during initialization! \n %s \n", pMessage); - delete [] pMessage; + XMLString::release(&pMessage); return -1; } 1.4 +2 -2 xml-xerces/c/tests/DOM/DeprecatedDOMCount/DeprecatedDOMCount.hpp Index: DeprecatedDOMCount.hpp =================================================================== RCS file: /home/cvs/xml-xerces/c/tests/DOM/DeprecatedDOMCount/DeprecatedDOMCount.hpp,v retrieving revision 1.3 retrieving revision 1.4 diff -u -r1.3 -r1.4 --- DeprecatedDOMCount.hpp 5 Nov 2002 21:47:35 -0000 1.3 +++ DeprecatedDOMCount.hpp 5 Feb 2003 18:55:20 -0000 1.4 @@ -137,7 +137,7 @@ ~StrX() { - delete [] fLocalForm; + XMLString::release(&fLocalForm); } 1.14 +2 -2 xml-xerces/c/tests/DOM/RangeTest/RangeTest.cpp Index: RangeTest.cpp =================================================================== RCS file: /home/cvs/xml-xerces/c/tests/DOM/RangeTest/RangeTest.cpp,v retrieving revision 1.13 retrieving revision 1.14 diff -u -r1.13 -r1.14 --- RangeTest.cpp 12 Nov 2002 17:52:25 -0000 1.13 +++ RangeTest.cpp 5 Feb 2003 18:55:20 -0000 1.14 @@ -197,7 +197,7 @@ char *pMessage = XMLString::transcode(toCatch.getMessage()); fprintf(stderr, "Error during XMLPlatformUtils::Initialize(). \n" " Message is: %s\n", pMessage); - delete [] pMessage; + XMLString::release(&pMessage); return -1; } 1.15 +4 -1 xml-xerces/c/tests/DOM/Traversal/Traversal.cpp Index: Traversal.cpp =================================================================== RCS file: /home/cvs/xml-xerces/c/tests/DOM/Traversal/Traversal.cpp,v retrieving revision 1.14 retrieving revision 1.15 diff -u -r1.14 -r1.15 --- Traversal.cpp 12 Nov 2002 17:52:12 -0000 1.14 +++ Traversal.cpp 5 Feb 2003 18:55:20 -0000 1.15 @@ -66,6 +66,9 @@ /** * $Log$ + * Revision 1.15 2003/02/05 18:55:20 tng + * [Bug 11915] Utility for freeing memory. + * * Revision 1.14 2002/11/12 17:52:12 tng * Test update: do not issue "Test Run Successfully" if there was an error. * @@ -203,7 +206,7 @@ char *pMessage = XMLString::transcode(toCatch.getMessage()); fprintf(stderr, "Error during XMLPlatformUtils::Initialize(). \n" " Message is: %s\n", pMessage); - delete [] pMessage; + XMLString::release(&pMessage); return -1; } 1.3 +2 -2 xml-xerces/c/tests/DOM/TypeInfo/TypeInfo.cpp Index: TypeInfo.cpp =================================================================== RCS file: /home/cvs/xml-xerces/c/tests/DOM/TypeInfo/TypeInfo.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -u -r1.2 -r1.3 --- TypeInfo.cpp 31 Jan 2003 19:40:35 -0000 1.2 +++ TypeInfo.cpp 5 Feb 2003 18:55:20 -0000 1.3 @@ -93,7 +93,7 @@ ~XStr() { - delete [] fUnicodeForm; + XMLString::release(&fUnicodeForm); } @@ -135,7 +135,7 @@ ~StrX() { - delete [] fLocalForm; + XMLString::release(&fLocalForm); } 1.10 +6 -6 xml-xerces/c/tests/EncodingTest/EncodingTest.cpp Index: EncodingTest.cpp =================================================================== RCS file: /home/cvs/xml-xerces/c/tests/EncodingTest/EncodingTest.cpp,v retrieving revision 1.9 retrieving revision 1.10 diff -u -r1.9 -r1.10 --- EncodingTest.cpp 5 Nov 2002 21:47:36 -0000 1.9 +++ EncodingTest.cpp 5 Feb 2003 18:55:21 -0000 1.10 @@ -114,8 +114,8 @@ systemId, e.getLineNumber(), e.getColumnNumber(), message); - delete [] systemId; - delete [] message; + XMLString::release(&systemId); + XMLString::release(&message); throw e; }; @@ -129,8 +129,8 @@ systemId, e.getLineNumber(), e.getColumnNumber(), message); - delete [] systemId; - delete [] message; + XMLString::release(&systemId); + XMLString::release(&message); throw e; }; @@ -143,8 +143,8 @@ systemId, e.getLineNumber(), e.getColumnNumber(), message); - delete [] systemId; - delete [] message; + XMLString::release(&systemId); + XMLString::release(&message); throw e; }; 1.6 +4 -4 xml-xerces/c/tests/InitTermTest/InitTermTest.cpp Index: InitTermTest.cpp =================================================================== RCS file: /home/cvs/xml-xerces/c/tests/InitTermTest/InitTermTest.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- InitTermTest.cpp 21 May 2002 18:54:16 -0000 1.5 +++ InitTermTest.cpp 5 Feb 2003 18:55:21 -0000 1.6 @@ -247,9 +247,9 @@ XMLCh* fullSchemaCheckFeature = XMLString::transcode("http://apache.org/xml/features/validation/schema-full-checking"); parser->setFeature(fullSchemaCheckFeature, gSchemaFullChecking); - delete [] doNamespaceFeature; - delete [] doSchemaFeature; - delete [] fullSchemaCheckFeature; + XMLString::release(&doNamespaceFeature); + XMLString::release(&doSchemaFeature); + XMLString::release(&fullSchemaCheckFeature); TESTINITPOST; } 1.6 +2 -2 xml-xerces/c/tests/InitTermTest/InitTermTest.hpp Index: InitTermTest.hpp =================================================================== RCS file: /home/cvs/xml-xerces/c/tests/InitTermTest/InitTermTest.hpp,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- InitTermTest.hpp 5 Nov 2002 21:47:36 -0000 1.5 +++ InitTermTest.hpp 5 Feb 2003 18:55:21 -0000 1.6 @@ -137,7 +137,7 @@ ~StrX() { - delete [] fLocalForm; + XMLString::release(&fLocalForm); } 1.7 +18 -13 xml-xerces/c/tests/ParserTest/ParserTest.hpp Index: ParserTest.hpp =================================================================== RCS file: /home/cvs/xml-xerces/c/tests/ParserTest/ParserTest.hpp,v retrieving revision 1.6 retrieving revision 1.7 diff -u -r1.6 -r1.7 --- ParserTest.hpp 2 Mar 2000 19:55:46 -0000 1.6 +++ ParserTest.hpp 5 Feb 2003 18:55:21 -0000 1.7 @@ -1,37 +1,37 @@ /* * The Apache Software License, Version 1.1 - * + * * Copyright (c) 1999-2000 The Apache Software Foundation. All rights * reserved. - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: - * + * * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * + * notice, this list of conditions and the following disclaimer. + * * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in * the documentation and/or other materials provided with the * distribution. - * + * * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: + * if any, must include the following acknowledgment: * "This product includes software developed by the * Apache Software Foundation (http://www.apache.org/)." * Alternately, this acknowledgment may appear in the software itself, * if and wherever such third-party acknowledgments normally appear. - * + * * 4. The names "Xerces" and "Apache Software Foundation" must * not be used to endorse or promote products derived from this - * software without prior written permission. For written + * software without prior written permission. For written * permission, please contact apache\@apache.org. - * + * * 5. Products derived from this software may not be called "Apache", * nor may "Apache" appear in their name, without prior written * permission of the Apache Software Foundation. - * + * * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE @@ -45,7 +45,7 @@ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * ==================================================================== - * + * * This software consists of voluntary contributions made by many * individuals on behalf of the Apache Software Foundation, and was * originally based on software copyright (c) 1999, International @@ -56,6 +56,9 @@ /* * $Log$ + * Revision 1.7 2003/02/05 18:55:21 tng + * [Bug 11915] Utility for freeing memory. + * * Revision 1.6 2000/03/02 19:55:46 roddey * This checkin includes many changes done while waiting for the * 1.1.0 code to be finished. I can't list them all here, but a list is @@ -121,7 +124,7 @@ ~StrX() { - delete [] fLocalForm; + XMLString::release(&fLocalForm); } 1.28 +4 -4 xml-xerces/c/tests/ThreadTest/ThreadTest.cpp Index: ThreadTest.cpp =================================================================== RCS file: /home/cvs/xml-xerces/c/tests/ThreadTest/ThreadTest.cpp,v retrieving revision 1.27 retrieving revision 1.28 diff -u -r1.27 -r1.28 --- ThreadTest.cpp 11 Dec 2002 20:04:53 -0000 1.27 +++ ThreadTest.cpp 5 Feb 2003 18:55:21 -0000 1.28 @@ -431,7 +431,7 @@ char *exceptionMessage = XMLString::transcode(e.getMessage()); fprintf(stderr, " during parsing: %s \n Exception message is: %s \n", fInfo->fileName, exceptionMessage); - delete [] exceptionMessage; + XMLString::release(&exceptionMessage); errors = true; } catch (const DOMException& toCatch) @@ -445,7 +445,7 @@ char *exceptionMessage = XMLString::transcode(e.getMessage()); fprintf(stderr, " during parsing: %s \n Exception message is: %s \n", fInfo->fileName, exceptionMessage); - delete [] exceptionMessage; + XMLString::release(&exceptionMessage); errors = true; } catch (...) @@ -808,7 +808,7 @@ for (fileNum = 0; fileNum <gRunInfo.numInputFiles; fileNum++) { InFileInfo *fInfo = &gRunInfo.files[fileNum]; - delete [] fInfo->uFileName; + XMLString::release(&fInfo->uFileName); delete [] fInfo->fileContent; } } 1.6 +16 -13 xml-xerces/c/tests/UtilTests/CoreTests_RefHashTable.cpp Index: CoreTests_RefHashTable.cpp =================================================================== RCS file: /home/cvs/xml-xerces/c/tests/UtilTests/CoreTests_RefHashTable.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -u -r1.5 -r1.6 --- CoreTests_RefHashTable.cpp 1 Feb 2002 22:46:28 -0000 1.5 +++ CoreTests_RefHashTable.cpp 5 Feb 2003 18:55:21 -0000 1.6 @@ -1,37 +1,37 @@ /* * The Apache Software License, Version 1.1 - * + * * Copyright (c) 1999-2000 The Apache Software Foundation. All rights * reserved. - * + * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions * are met: - * + * * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * + * notice, this list of conditions and the following disclaimer. + * * 2. Redistributions in binary form must reproduce the above copyright * notice, this list of conditions and the following disclaimer in * the documentation and/or other materials provided with the * distribution. - * + * * 3. The end-user documentation included with the redistribution, - * if any, must include the following acknowledgment: + * if any, must include the following acknowledgment: * "This product includes software developed by the * Apache Software Foundation (http://www.apache.org/)." * Alternately, this acknowledgment may appear in the software itself, * if and wherever such third-party acknowledgments normally appear. - * + * * 4. The names "Xerces" and "Apache Software Foundation" must * not be used to endorse or promote products derived from this - * software without prior written permission. For written + * software without prior written permission. For written * permission, please contact apache\@apache.org. - * + * * 5. Products derived from this software may not be called "Apache", * nor may "Apache" appear in their name, without prior written * permission of the Apache Software Foundation. - * + * * THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED * WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE @@ -45,7 +45,7 @@ * OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF * SUCH DAMAGE. * ==================================================================== - * + * * This software consists of voluntary contributions made by many * individuals on behalf of the Apache Software Foundation, and was * originally based on software copyright (c) 1999, International @@ -56,6 +56,9 @@ /* * $Log$ + * Revision 1.6 2003/02/05 18:55:21 tng + * [Bug 11915] Utility for freeing memory. + * * Revision 1.5 2002/02/01 22:46:28 peiyongz * sane_include * @@ -102,7 +105,7 @@ ~TestElem() { - delete [] fKey; + XMLString::release(&fKey); } const XMLCh* getKey() const
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]