You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@xerces.apache.org by am...@apache.org on 2006/05/19 20:25:14 UTC
svn commit: r407876 [1/2] - in /xerces/c/trunk: samples/src/PSVIWriter/
samples/src/SEnumVal/ scripts/ src/xercesc/dom/impl/ src/xercesc/framework/
src/xercesc/internal/ src/xercesc/util/ src/xercesc/util/FileManagers/
src/xercesc/util/NetAccessors/Soc...
Author: amassari
Date: Fri May 19 11:25:12 2006
New Revision: 407876
URL: http://svn.apache.org/viewvc?rev=407876&view=rev
Log:
Make it compile cleanly (except XSValueTest..) with gcc -Wall -Wextra
Modified:
xerces/c/trunk/samples/src/PSVIWriter/PSVIWriterHandlers.cpp
xerces/c/trunk/samples/src/PSVIWriter/PSVIWriterHandlers.hpp
xerces/c/trunk/samples/src/SEnumVal/SEnumVal.cpp
xerces/c/trunk/scripts/sanityTest_ExpectedResult.log
xerces/c/trunk/src/xercesc/dom/impl/DOMImplementationImpl.cpp
xerces/c/trunk/src/xercesc/dom/impl/DOMLSSerializerImpl.cpp
xerces/c/trunk/src/xercesc/dom/impl/DOMTypeInfoImpl.cpp
xerces/c/trunk/src/xercesc/framework/XMLFormatter.cpp
xerces/c/trunk/src/xercesc/internal/IGXMLScanner.cpp
xerces/c/trunk/src/xercesc/internal/SGXMLScanner.cpp
xerces/c/trunk/src/xercesc/internal/XMLReader.cpp
xerces/c/trunk/src/xercesc/internal/XSerializeEngine.cpp
xerces/c/trunk/src/xercesc/util/Base64.cpp
xerces/c/trunk/src/xercesc/util/FileManagers/PosixFileMgr.cpp
xerces/c/trunk/src/xercesc/util/NetAccessors/Socket/UnixHTTPURLInputStream.cpp
xerces/c/trunk/src/xercesc/util/Transcoders/ICU/ICUTransService.cpp
xerces/c/trunk/src/xercesc/validators/DTD/DTDValidator.cpp
xerces/c/trunk/src/xercesc/validators/common/CMAny.cpp
xerces/c/trunk/src/xercesc/validators/common/CMAny.hpp
xerces/c/trunk/src/xercesc/validators/common/CMLeaf.hpp
xerces/c/trunk/src/xercesc/validators/common/CMNode.hpp
xerces/c/trunk/src/xercesc/validators/common/DFAContentModel.cpp
xerces/c/trunk/src/xercesc/validators/schema/ComplexTypeInfo.hpp
xerces/c/trunk/src/xercesc/validators/schema/SchemaElementDecl.hpp
xerces/c/trunk/src/xercesc/validators/schema/TraverseSchema.cpp
xerces/c/trunk/src/xercesc/validators/schema/XercesGroupInfo.cpp
xerces/c/trunk/src/xercesc/validators/schema/XercesGroupInfo.hpp
xerces/c/trunk/src/xercesc/validators/schema/identity/XercesXPath.cpp
xerces/c/trunk/swig/perl/Xerces.cpp
xerces/c/trunk/tests/src/DOM/DOMMemTest/DOMMemTest.cpp
xerces/c/trunk/tests/src/DOM/DOMTest/DTest.cpp
xerces/c/trunk/tests/src/DOM/Normalizer/Normalizer.cpp
xerces/c/trunk/tests/src/DOM/RangeTest/RangeTest.cpp
xerces/c/trunk/tests/src/DOM/Traversal/Traversal.cpp
xerces/c/trunk/tests/src/DOM/TypeInfo/TypeInfo.cpp
xerces/c/trunk/tests/src/MemHandlerTest/MemoryMonitor.cpp
xerces/c/trunk/tests/src/ThreadTest/ThreadTest.cpp
xerces/c/trunk/tests/src/XSValueTest/XSValueTest.cpp
xerces/c/trunk/tests/src/XSerializerTest/XSerializerHandlers.cpp
Modified: xerces/c/trunk/samples/src/PSVIWriter/PSVIWriterHandlers.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/samples/src/PSVIWriter/PSVIWriterHandlers.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/samples/src/PSVIWriter/PSVIWriterHandlers.cpp (original)
+++ xerces/c/trunk/samples/src/PSVIWriter/PSVIWriterHandlers.cpp Fri May 19 11:25:12 2006
@@ -286,7 +286,7 @@
return 0;
}
-InputSource* PSVIWriterHandlers::resolveEntity(const XMLCh* const publicId, const XMLCh* const systemId) {
+InputSource* PSVIWriterHandlers::resolveEntity(const XMLCh* const, const XMLCh* const) {
return 0;
}
@@ -1791,7 +1791,7 @@
case XSValue::dt_integer:
{
writeValue(gDataType, SchemaSymbols::fgDT_INTEGER);
- sprintf( buffer,"%d", obj->fData.fValue.f_long);
+ sprintf( buffer,"%ld", obj->fData.fValue.f_long);
XMLCh *value = XMLString::transcode(buffer);
ArrayJanitor<XMLCh> jan(value);
writeValue(gDataValue, value);
@@ -1800,7 +1800,7 @@
case XSValue::dt_nonPositiveInteger:
{
writeValue(gDataType, SchemaSymbols::fgDT_NONPOSITIVEINTEGER);
- sprintf( buffer,"%d", obj->fData.fValue.f_long);
+ sprintf( buffer,"%ld", obj->fData.fValue.f_long);
XMLCh *value = XMLString::transcode(buffer);
ArrayJanitor<XMLCh> jan(value);
writeValue(gDataValue, value);
@@ -1809,7 +1809,7 @@
case XSValue::dt_negativeInteger:
{
writeValue(gDataType, SchemaSymbols::fgDT_NEGATIVEINTEGER);
- sprintf( buffer,"%d", obj->fData.fValue.f_long);
+ sprintf( buffer,"%ld", obj->fData.fValue.f_long);
XMLCh *value = XMLString::transcode(buffer);
ArrayJanitor<XMLCh> jan(value);
writeValue(gDataValue, value);
@@ -1818,7 +1818,7 @@
case XSValue::dt_long:
{
writeValue(gDataType, SchemaSymbols::fgDT_LONG);
- sprintf( buffer,"%d", obj->fData.fValue.f_long);
+ sprintf( buffer,"%ld", obj->fData.fValue.f_long);
XMLCh *value = XMLString::transcode(buffer);
ArrayJanitor<XMLCh> jan(value);
writeValue(gDataValue, value);
@@ -1854,7 +1854,7 @@
case XSValue::dt_nonNegativeInteger:
{
writeValue(gDataType, SchemaSymbols::fgDT_NONNEGATIVEINTEGER);
- sprintf( buffer,"%u", obj->fData.fValue.f_long);
+ sprintf( buffer,"%ld", obj->fData.fValue.f_long);
XMLCh *value = XMLString::transcode(buffer);
ArrayJanitor<XMLCh> jan(value);
writeValue(gDataValue, value);
@@ -1863,7 +1863,7 @@
case XSValue::dt_unsignedLong:
{
writeValue(gDataType, SchemaSymbols::fgDT_ULONG);
- sprintf( buffer,"%u", obj->fData.fValue.f_ulong);
+ sprintf( buffer,"%lu", obj->fData.fValue.f_ulong);
XMLCh *value = XMLString::transcode(buffer);
ArrayJanitor<XMLCh> jan(value);
writeValue(gDataValue, value);
@@ -1899,7 +1899,7 @@
case XSValue::dt_positiveInteger:
{
writeValue(gDataType, SchemaSymbols::fgDT_POSITIVEINTEGER);
- sprintf( buffer,"%u", obj->fData.fValue.f_long);
+ sprintf( buffer,"%ld", obj->fData.fValue.f_long);
XMLCh *value = XMLString::transcode(buffer);
ArrayJanitor<XMLCh> jan(value);
writeValue(gDataValue, value);
Modified: xerces/c/trunk/samples/src/PSVIWriter/PSVIWriterHandlers.hpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/samples/src/PSVIWriter/PSVIWriterHandlers.hpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/samples/src/PSVIWriter/PSVIWriterHandlers.hpp (original)
+++ xerces/c/trunk/samples/src/PSVIWriter/PSVIWriterHandlers.hpp Fri May 19 11:25:12 2006
@@ -291,7 +291,7 @@
void endElement(const XMLElementDecl&, const unsigned int, const bool, const XMLCh* const) {}
void endEntityReference(const XMLEntityDecl&) {}
- void ignorableWhitespace(const XMLCh* const chars, const unsigned int length, const bool cdataSection) {}
+ void ignorableWhitespace(const XMLCh* const, const unsigned int, const bool) {}
void resetDocument() {}
void startDocument() {}
Modified: xerces/c/trunk/samples/src/SEnumVal/SEnumVal.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/samples/src/SEnumVal/SEnumVal.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/samples/src/SEnumVal/SEnumVal.cpp (original)
+++ xerces/c/trunk/samples/src/SEnumVal/SEnumVal.cpp Fri May 19 11:25:12 2006
@@ -398,8 +398,8 @@
case DatatypeValidator::String: XERCES_STD_QUALIFIER cout << "string"; break;
case DatatypeValidator::AnyURI: XERCES_STD_QUALIFIER cout << "AnyURI"; break;
case DatatypeValidator::QName: XERCES_STD_QUALIFIER cout << "QName"; break;
- case DatatypeValidator::Name: XERCES_STD_QUALIFIER cout << "Name"; break;
- case DatatypeValidator::NCName: XERCES_STD_QUALIFIER cout << "NCName"; break;
+ case DatatypeValidator::Name: XERCES_STD_QUALIFIER cout << "Name"; break;
+ case DatatypeValidator::NCName: XERCES_STD_QUALIFIER cout << "NCName"; break;
case DatatypeValidator::Boolean: XERCES_STD_QUALIFIER cout << "Boolean"; break;
case DatatypeValidator::Float: XERCES_STD_QUALIFIER cout << "Float"; break;
case DatatypeValidator::Double: XERCES_STD_QUALIFIER cout << "Double"; break;
@@ -422,6 +422,7 @@
case DatatypeValidator::List: XERCES_STD_QUALIFIER cout << "List"; break;
case DatatypeValidator::Union: XERCES_STD_QUALIFIER cout << "Union"; break;
case DatatypeValidator::AnySimpleType: XERCES_STD_QUALIFIER cout << "AnySimpleType"; break;
+ case DatatypeValidator::UnKnown: XERCES_STD_QUALIFIER cout << "UNKNOWN"; break;
}
XERCES_STD_QUALIFIER cout << "\n";
@@ -475,23 +476,26 @@
XERCES_STD_QUALIFIER cout << "ContentType:\t";
switch( cSpecNode->getType() )
{
- case ContentSpecNode::Leaf: XERCES_STD_QUALIFIER cout << "Leaf"; break;
- case ContentSpecNode::ZeroOrOne: XERCES_STD_QUALIFIER cout << "ZeroOrOne"; break;
- case ContentSpecNode::ZeroOrMore: XERCES_STD_QUALIFIER cout << "ZeroOrMore"; break;
- case ContentSpecNode::OneOrMore: XERCES_STD_QUALIFIER cout << "OneOrMore"; break;
- case ContentSpecNode::Choice: XERCES_STD_QUALIFIER cout << "Choice"; break;
- case ContentSpecNode::Sequence: XERCES_STD_QUALIFIER cout << "Sequence"; break;
- case ContentSpecNode::All: XERCES_STD_QUALIFIER cout << "All"; break;
- case ContentSpecNode::Any: XERCES_STD_QUALIFIER cout << "Any"; break;
- case ContentSpecNode::Any_Other: XERCES_STD_QUALIFIER cout << "Any_Other"; break;
- case ContentSpecNode::Any_NS: XERCES_STD_QUALIFIER cout << "Any_NS"; break;
- case ContentSpecNode::Any_Lax: XERCES_STD_QUALIFIER cout << "Any_Lax"; break;
- case ContentSpecNode::Any_Other_Lax: XERCES_STD_QUALIFIER cout << "Any_Other_Lax"; break;
- case ContentSpecNode::Any_NS_Lax: XERCES_STD_QUALIFIER cout << "Any_NS_Lax"; break;
- case ContentSpecNode::Any_Skip: XERCES_STD_QUALIFIER cout << "Any_Skip"; break;
- case ContentSpecNode::Any_Other_Skip: XERCES_STD_QUALIFIER cout << "Any_Other_Skip"; break;
- case ContentSpecNode::Any_NS_Skip: XERCES_STD_QUALIFIER cout << "Any_NS_Skip"; break;
- case ContentSpecNode::UnknownType: XERCES_STD_QUALIFIER cout << "UnknownType"; break;
+ case ContentSpecNode::Leaf: XERCES_STD_QUALIFIER cout << "Leaf"; break;
+ case ContentSpecNode::ZeroOrOne: XERCES_STD_QUALIFIER cout << "ZeroOrOne"; break;
+ case ContentSpecNode::ZeroOrMore: XERCES_STD_QUALIFIER cout << "ZeroOrMore"; break;
+ case ContentSpecNode::OneOrMore: XERCES_STD_QUALIFIER cout << "OneOrMore"; break;
+ case ContentSpecNode::Choice: XERCES_STD_QUALIFIER cout << "Choice"; break;
+ case ContentSpecNode::Sequence: XERCES_STD_QUALIFIER cout << "Sequence"; break;
+ case ContentSpecNode::All: XERCES_STD_QUALIFIER cout << "All"; break;
+ case ContentSpecNode::Any: XERCES_STD_QUALIFIER cout << "Any"; break;
+ case ContentSpecNode::Any_Other: XERCES_STD_QUALIFIER cout << "Any_Other"; break;
+ case ContentSpecNode::Any_NS: XERCES_STD_QUALIFIER cout << "Any_NS"; break;
+ case ContentSpecNode::Any_Lax: XERCES_STD_QUALIFIER cout << "Any_Lax"; break;
+ case ContentSpecNode::Any_Other_Lax: XERCES_STD_QUALIFIER cout << "Any_Other_Lax"; break;
+ case ContentSpecNode::Any_NS_Lax: XERCES_STD_QUALIFIER cout << "Any_NS_Lax"; break;
+ case ContentSpecNode::Any_Skip: XERCES_STD_QUALIFIER cout << "Any_Skip"; break;
+ case ContentSpecNode::Any_Other_Skip: XERCES_STD_QUALIFIER cout << "Any_Other_Skip"; break;
+ case ContentSpecNode::Any_NS_Skip: XERCES_STD_QUALIFIER cout << "Any_NS_Skip"; break;
+ case ContentSpecNode::Any_NS_Choice: XERCES_STD_QUALIFIER cout << "Any_NS_Choice"; break;
+ case ContentSpecNode::ModelGroupSequence: XERCES_STD_QUALIFIER cout << "ModelGroupSequence"; break;
+ case ContentSpecNode::ModelGroupChoice: XERCES_STD_QUALIFIER cout << "ModelGroupChoice"; break;
+ case ContentSpecNode::UnknownType: XERCES_STD_QUALIFIER cout << "UnknownType"; break;
}
XERCES_STD_QUALIFIER cout << "\n";
}
Modified: xerces/c/trunk/scripts/sanityTest_ExpectedResult.log
URL: http://svn.apache.org/viewvc/xerces/c/trunk/scripts/sanityTest_ExpectedResult.log?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/scripts/sanityTest_ExpectedResult.log (original)
+++ xerces/c/trunk/scripts/sanityTest_ExpectedResult.log Fri May 19 11:25:12 2006
@@ -981,20 +981,20 @@
Name: personnel
Model Type: Children
Create Reason: Declared
-ContentType:
+ContentType: ModelGroupSequence
Content Model: (person,)
ComplexType:
TypeName: ,__AnonC0
- ContentType:
+ ContentType: ModelGroupSequence
--------------------------------------------
Name: person
Model Type: Children
Create Reason: Declared
-ContentType:
+ContentType: ModelGroupSequence
Content Model: ((name,email,url),link)
ComplexType:
TypeName: ,__AnonC1
- ContentType:
+ ContentType: ModelGroupSequence
Attributes:
Name: id
Type: ID
Modified: xerces/c/trunk/src/xercesc/dom/impl/DOMImplementationImpl.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/dom/impl/DOMImplementationImpl.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/dom/impl/DOMImplementationImpl.cpp (original)
+++ xerces/c/trunk/src/xercesc/dom/impl/DOMImplementationImpl.cpp Fri May 19 11:25:12 2006
@@ -268,9 +268,9 @@
bool DOMImplementation::loadDOMExceptionMsg
(
- const DOMLSException::LSExceptionCode msgToLoad
- , XMLCh* const toFill
- , const unsigned int maxChars
+ const DOMLSException::LSExceptionCode /*msgToLoad*/
+ , XMLCh* const /*toFill*/
+ , const unsigned int /*maxChars*/
)
{
// load the text, the msgToLoad+XMLDOMMsgs::DOMLSEXCEPTION_ERRX+msgToLoad is the corresponding XMLDOMMsg Code
@@ -295,7 +295,7 @@
// ------------------------------------------------------------
//Introduced in DOM Level 3
DOMLSParser* DOMImplementationImpl::createLSParser( const unsigned short mode,
- const XMLCh* const schemaType,
+ const XMLCh* const /*schemaType*/,
MemoryManager* const manager,
XMLGrammarPool* const gramPool)
{
Modified: xerces/c/trunk/src/xercesc/dom/impl/DOMLSSerializerImpl.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/dom/impl/DOMLSSerializerImpl.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/dom/impl/DOMLSSerializerImpl.cpp (original)
+++ xerces/c/trunk/src/xercesc/dom/impl/DOMLSSerializerImpl.cpp Fri May 19 11:25:12 2006
@@ -339,7 +339,7 @@
}
bool DOMLSSerializerImpl::canSetParameter(const XMLCh* const featName
- , const void* value) const
+ , const void* /*value*/) const
{
if(XMLString::compareIStringASCII(featName, XMLUni::fgDOMErrorHandler)==0)
return true;
Modified: xerces/c/trunk/src/xercesc/dom/impl/DOMTypeInfoImpl.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/dom/impl/DOMTypeInfoImpl.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/dom/impl/DOMTypeInfoImpl.cpp (original)
+++ xerces/c/trunk/src/xercesc/dom/impl/DOMTypeInfoImpl.cpp Fri May 19 11:25:12 2006
@@ -111,7 +111,7 @@
return fTypeNamespace;
}
-bool DOMTypeInfoImpl::isDerivedFrom(const XMLCh* typeNamespaceArg, const XMLCh* typeNameArg, unsigned long derivationMethod) const
+bool DOMTypeInfoImpl::isDerivedFrom(const XMLCh* typeNamespaceArg, const XMLCh* typeNameArg, unsigned long /*derivationMethod*/) const
{
// if it's a DTD, return false
if(!getNumericProperty(PSVI_Schema_Specified))
Modified: xerces/c/trunk/src/xercesc/framework/XMLFormatter.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/framework/XMLFormatter.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/framework/XMLFormatter.cpp (original)
+++ xerces/c/trunk/src/xercesc/framework/XMLFormatter.cpp Fri May 19 11:25:12 2006
@@ -505,8 +505,7 @@
unsigned int count = oCount;
while (count) {
- const unsigned srcChars
- = count > kTmpBufSize ? kTmpBufSize : count;
+ const unsigned srcChars = (count > kTmpBufSize) ? (int)kTmpBufSize : count;
const unsigned int outBytes
= fXCoder->transcodeTo(srcPtr, srcChars,
Modified: xerces/c/trunk/src/xercesc/internal/IGXMLScanner.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/internal/IGXMLScanner.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/internal/IGXMLScanner.cpp (original)
+++ xerces/c/trunk/src/xercesc/internal/IGXMLScanner.cpp Fri May 19 11:25:12 2006
@@ -2159,7 +2159,7 @@
// save the contentleafname and currentscope before addlevel, for later use
ContentLeafNameTypeVector* cv = 0;
XMLContentModel* cm = 0;
- int currentScope = Grammar::TOP_LEVEL_SCOPE;
+ unsigned int currentScope = Grammar::TOP_LEVEL_SCOPE;
bool laxThisOne = false;
if (!isRoot && fGrammarType == Grammar::SchemaGrammarType)
Modified: xerces/c/trunk/src/xercesc/internal/SGXMLScanner.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/internal/SGXMLScanner.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/internal/SGXMLScanner.cpp (original)
+++ xerces/c/trunk/src/xercesc/internal/SGXMLScanner.cpp Fri May 19 11:25:12 2006
@@ -1116,7 +1116,7 @@
// save the contentleafname and currentscope before addlevel, for later use
ContentLeafNameTypeVector* cv = 0;
XMLContentModel* cm = 0;
- int currentScope = Grammar::TOP_LEVEL_SCOPE;
+ unsigned int currentScope = Grammar::TOP_LEVEL_SCOPE;
bool laxThisOne = false;
if (!isRoot)
{
Modified: xerces/c/trunk/src/xercesc/internal/XMLReader.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/internal/XMLReader.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/internal/XMLReader.cpp (original)
+++ xerces/c/trunk/src/xercesc/internal/XMLReader.cpp Fri May 19 11:25:12 2006
@@ -260,6 +260,15 @@
}
break;
}
+ case XMLRecognizer::EBCDIC:
+ case XMLRecognizer::US_ASCII:
+ case XMLRecognizer::XERCES_XMLCH:
+ case XMLRecognizer::OtherEncoding:
+ case XMLRecognizer::Encodings_Count:
+ {
+ // silence warning about enumeration not being used
+ break;
+ }
}
// Check whether the fSwapped flag should be set or not
Modified: xerces/c/trunk/src/xercesc/internal/XSerializeEngine.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/internal/XSerializeEngine.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/internal/XSerializeEngine.cpp (original)
+++ xerces/c/trunk/src/xercesc/internal/XSerializeEngine.cpp Fri May 19 11:25:12 2006
@@ -1133,9 +1133,9 @@
return;
if (isStoring())
- printf("\n funcName=<%s>, storing, count=<%d>, postion=<%d>\n", funcName, fBufCount, getBufCurAccumulated());
+ printf("\n funcName=<%s>, storing, count=<%lu>, postion=<%lu>\n", funcName, fBufCount, getBufCurAccumulated());
else
- printf("\n funcName=<%s>, loading, count=<%d>, postion=<%d>\n", funcName, fBufCount, getBufCurAccumulated());
+ printf("\n funcName=<%s>, loading, count=<%lu>, postion=<%lu>\n", funcName, fBufCount, getBufCurAccumulated());
}
XERCES_CPP_NAMESPACE_END
Modified: xerces/c/trunk/src/xercesc/util/Base64.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/util/Base64.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/util/Base64.cpp (original)
+++ xerces/c/trunk/src/xercesc/util/Base64.cpp Fri May 19 11:25:12 2006
@@ -99,11 +99,6 @@
: ::operator new(sizeToAllocate);
}
-static void* getInternalMemory(unsigned int const sizeToAllocate)
-{
- return XMLPlatformUtils::fgMemoryManager->allocate(sizeToAllocate);
-}
-
/***
* internal memory is deallocated by janitorArray
*/
Modified: xerces/c/trunk/src/xercesc/util/FileManagers/PosixFileMgr.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/util/FileManagers/PosixFileMgr.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/util/FileManagers/PosixFileMgr.cpp (original)
+++ xerces/c/trunk/src/xercesc/util/FileManagers/PosixFileMgr.cpp Fri May 19 11:25:12 2006
@@ -54,16 +54,16 @@
FileHandle
-PosixFileMgr::open(const char* path, bool toWrite, MemoryManager* const manager)
+PosixFileMgr::open(const char* path, bool toWrite, MemoryManager* const /*manager*/)
{
- const char* perms = (toWrite) ? "wb" : "rb";
+ const char* perms = (toWrite) ? "wb" : "rb";
FileHandle result = (FileHandle)fopen(path , perms);
return result;
}
FileHandle
-PosixFileMgr::openStdIn(MemoryManager* const manager)
+PosixFileMgr::openStdIn(MemoryManager* const /*manager*/)
{
return (FileHandle)fdopen(dup(0), "rb");
}
@@ -211,7 +211,7 @@
bool
-PosixFileMgr::isRelative(const XMLCh* const toCheck, MemoryManager* const manager)
+PosixFileMgr::isRelative(const XMLCh* const toCheck, MemoryManager* const /*manager*/)
{
// Check for pathological case of empty path
if (!toCheck || !toCheck[0])
Modified: xerces/c/trunk/src/xercesc/util/NetAccessors/Socket/UnixHTTPURLInputStream.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/util/NetAccessors/Socket/UnixHTTPURLInputStream.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/util/NetAccessors/Socket/UnixHTTPURLInputStream.cpp (original)
+++ xerces/c/trunk/src/xercesc/util/NetAccessors/Socket/UnixHTTPURLInputStream.cpp Fri May 19 11:25:12 2006
@@ -253,12 +253,7 @@
// Use the hostName in the local code page ....
if ((hostEntPtr = gethostbyname(hostNameAsCharStar)) == NULL)
{
- unsigned long numAddress = inet_addr(hostNameAsCharStar);
- if (numAddress < 0)
- {
- ThrowXMLwithMemMgr1(NetAccessorException,
- XMLExcepts::NetAcc_TargetResolution, hostName, fMemoryManager);
- }
+ unsigned long numAddress = inet_addr(hostNameAsCharStar);
if ((hostEntPtr =
gethostbyaddr((char *) &numAddress,
sizeof(unsigned long), AF_INET)) == NULL)
@@ -470,11 +465,12 @@
// There was no data in the local buffer.
// Read some from the socket, straight into our caller's buffer.
//
- len = read(fSocket, (void *) toFill, maxToRead);
- if (len == -1)
+ int cbRead = read(fSocket, (void *) toFill, maxToRead);
+ if (cbRead == -1)
{
ThrowXMLwithMemMgr(NetAccessorException, XMLExcepts::NetAcc_ReadSocket, fMemoryManager);
}
+ len = cbRead;
}
fBytesProcessed += len;
Modified: xerces/c/trunk/src/xercesc/util/Transcoders/ICU/ICUTransService.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/util/Transcoders/ICU/ICUTransService.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/util/Transcoders/ICU/ICUTransService.cpp (original)
+++ xerces/c/trunk/src/xercesc/util/Transcoders/ICU/ICUTransService.cpp Fri May 19 11:25:12 2006
@@ -862,7 +862,7 @@
}
unsigned int ICULCPTranscoder::calcRequiredSize(const char* const srcText
- , MemoryManager* const manager)
+ , MemoryManager* const /*manager*/)
{
if (!srcText)
return 0;
Modified: xerces/c/trunk/src/xercesc/validators/DTD/DTDValidator.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/validators/DTD/DTDValidator.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/validators/DTD/DTDValidator.cpp (original)
+++ xerces/c/trunk/src/xercesc/validators/DTD/DTDValidator.cpp Fri May 19 11:25:12 2006
@@ -381,7 +381,7 @@
}
-void DTDValidator::preContentValidation(bool reuseGrammar,
+void DTDValidator::preContentValidation(bool /*reuseGrammar*/,
bool validateDefAttr)
{
//
Modified: xerces/c/trunk/src/xercesc/validators/common/CMAny.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/validators/common/CMAny.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/validators/common/CMAny.cpp (original)
+++ xerces/c/trunk/src/xercesc/validators/common/CMAny.cpp Fri May 19 11:25:12 2006
@@ -43,9 +43,8 @@
&& (type & 0x0f) != ContentSpecNode::Any_Other
&& (type & 0x0f) != ContentSpecNode::Any_NS)
{
- ThrowXMLwithMemMgr1(RuntimeException,
- XMLExcepts::CM_NotValidSpecTypeForNode,
- "CMAny", manager);
+ ThrowXMLwithMemMgr1(RuntimeException, XMLExcepts::CM_NotValidSpecTypeForNode,
+ "CMAny", manager);
}
}
@@ -59,7 +58,7 @@
// ---------------------------------------------------------------------------
unsigned int CMAny::getURI() const
{
- return fURI;
+ return fURI;
}
unsigned int CMAny::getPosition() const
@@ -81,7 +80,7 @@
bool CMAny::isNullable() const
{
// Leaf nodes are never nullable unless its an epsilon node
- return (fPosition == -1);
+ return (fPosition == epsilonNode);
}
// ---------------------------------------------------------------------------
@@ -90,25 +89,21 @@
void CMAny::calcFirstPos(CMStateSet& toSet) const
{
// If we are an epsilon node, then the first pos is an empty set
- if (fPosition == -1)
+ if (isNullable())
toSet.zeroBits();
else
// Otherwise, its just the one bit of our position
toSet.setBit(fPosition);
-
- return;
}
void CMAny::calcLastPos(CMStateSet& toSet) const
{
// If we are an epsilon node, then the last pos is an empty set
- if (fPosition == -1)
+ if (isNullable())
toSet.zeroBits();
// Otherwise, its just the one bit of our position
else
toSet.setBit(fPosition);
-
- return;
}
XERCES_CPP_NAMESPACE_END
Modified: xerces/c/trunk/src/xercesc/validators/common/CMAny.hpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/validators/common/CMAny.hpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/validators/common/CMAny.hpp (original)
+++ xerces/c/trunk/src/xercesc/validators/common/CMAny.hpp Fri May 19 11:25:12 2006
@@ -77,7 +77,7 @@
// XMLContentSpec.CONTENTSPECNODE_ANY,
// XMLContentSpec.CONTENTSPECNODE_ANY_OTHER.
//
- // fPosition
+ // fPosition
// Part of the algorithm to convert a regex directly to a DFA
// numbers each leaf sequentially. If its -1, that means its an
// epsilon node. Zero and greater are non-epsilon positions.
Modified: xerces/c/trunk/src/xercesc/validators/common/CMLeaf.hpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/validators/common/CMLeaf.hpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/validators/common/CMLeaf.hpp (original)
+++ xerces/c/trunk/src/xercesc/validators/common/CMLeaf.hpp Fri May 19 11:25:12 2006
@@ -40,7 +40,7 @@
CMLeaf
(
QName* const element
- , const unsigned int position = (~0)
+ , const unsigned int position
, MemoryManager* const manager = XMLPlatformUtils::fgMemoryManager
);
CMLeaf
@@ -205,7 +205,7 @@
inline bool CMLeaf::isNullable() const
{
// Leaf nodes are never nullable unless its an epsilon node
- return (fPosition == -1);
+ return (fPosition == epsilonNode);
}
@@ -215,7 +215,7 @@
inline void CMLeaf::calcFirstPos(CMStateSet& toSet) const
{
// If we are an epsilon node, then the first pos is an empty set
- if (fPosition == -1)
+ if (isNullable())
{
toSet.zeroBits();
return;
@@ -228,7 +228,7 @@
inline void CMLeaf::calcLastPos(CMStateSet& toSet) const
{
// If we are an epsilon node, then the last pos is an empty set
- if (fPosition == -1)
+ if (isNullable())
{
toSet.zeroBits();
return;
Modified: xerces/c/trunk/src/xercesc/validators/common/CMNode.hpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/validators/common/CMNode.hpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/validators/common/CMNode.hpp (original)
+++ xerces/c/trunk/src/xercesc/validators/common/CMNode.hpp Fri May 19 11:25:12 2006
@@ -21,6 +21,8 @@
#if !defined(CMNODE_HPP)
#define CMNODE_HPP
+#include <limits.h>
+
#include <xercesc/validators/common/ContentSpecNode.hpp>
#include <xercesc/validators/common/CMStateSet.hpp>
@@ -29,6 +31,11 @@
class CMNode : public XMemory
{
public :
+ enum {
+ // Special value to indicate a nullable node
+ epsilonNode = UINT_MAX - 1
+ };
+
// -----------------------------------------------------------------------
// Constructors and Destructors
// -----------------------------------------------------------------------
Modified: xerces/c/trunk/src/xercesc/validators/common/DFAContentModel.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/validators/common/DFAContentModel.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/validators/common/DFAContentModel.cpp (original)
+++ xerces/c/trunk/src/xercesc/validators/common/DFAContentModel.cpp Fri May 19 11:25:12 2006
@@ -375,7 +375,7 @@
, XMLContentModel::gEOCFakeId
, fMemoryManager
)
- , ~0
+ , CMNode::epsilonNode
, true
, fMemoryManager
);
Modified: xerces/c/trunk/src/xercesc/validators/schema/ComplexTypeInfo.hpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/validators/schema/ComplexTypeInfo.hpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/validators/schema/ComplexTypeInfo.hpp (original)
+++ xerces/c/trunk/src/xercesc/validators/schema/ComplexTypeInfo.hpp Fri May 19 11:25:12 2006
@@ -71,7 +71,7 @@
int getDerivedBy() const;
int getBlockSet() const;
int getFinalSet() const;
- int getScopeDefined() const;
+ unsigned int getScopeDefined() const;
unsigned int getElementId() const;
int getContentType() const;
unsigned int elementCount() const;
@@ -110,7 +110,7 @@
void setDerivedBy(const int derivedBy);
void setBlockSet(const int blockSet);
void setFinalSet(const int finalSet);
- void setScopeDefined(const int scopeDefined);
+ void setScopeDefined(const unsigned int scopeDefined);
void setElementId(const unsigned int elemId);
void setTypeName(const XMLCh* const typeName);
void setContentType(const int contentType);
@@ -202,7 +202,7 @@
int fDerivedBy;
int fBlockSet;
int fFinalSet;
- int fScopeDefined;
+ unsigned int fScopeDefined;
int fContentType;
unsigned int fElementId;
@@ -267,7 +267,7 @@
return fFinalSet;
}
-inline int ComplexTypeInfo::getScopeDefined() const {
+inline unsigned int ComplexTypeInfo::getScopeDefined() const {
return fScopeDefined;
}
@@ -422,7 +422,7 @@
fFinalSet = finalSet;
}
-inline void ComplexTypeInfo::setScopeDefined(const int scopeDefined) {
+inline void ComplexTypeInfo::setScopeDefined(const unsigned int scopeDefined) {
fScopeDefined = scopeDefined;
}
Modified: xerces/c/trunk/src/xercesc/validators/schema/SchemaElementDecl.hpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/validators/schema/SchemaElementDecl.hpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/validators/schema/SchemaElementDecl.hpp (original)
+++ xerces/c/trunk/src/xercesc/validators/schema/SchemaElementDecl.hpp Fri May 19 11:25:12 2006
@@ -121,7 +121,7 @@
ModelTypes getModelType() const;
PSVIDefs::PSVIScope getPSVIScope() const;
DatatypeValidator* getDatatypeValidator() const;
- int getEnclosingScope() const;
+ unsigned int getEnclosingScope() const;
int getFinalSet() const;
int getBlockSet() const;
int getMiscFlags() const;
@@ -140,7 +140,7 @@
void setModelType(const SchemaElementDecl::ModelTypes toSet);
void setPSVIScope(const PSVIDefs::PSVIScope toSet);
void setDatatypeValidator(DatatypeValidator* newDatatypeValidator);
- void setEnclosingScope(const int enclosingScope);
+ void setEnclosingScope(const unsigned int enclosingScope);
void setFinalSet(const int finalSet);
void setBlockSet(const int blockSet);
void setMiscFlags(const int flags);
@@ -220,7 +220,7 @@
ModelTypes fModelType;
PSVIDefs::PSVIScope fPSVIScope;
- int fEnclosingScope;
+ unsigned int fEnclosingScope;
int fFinalSet;
int fBlockSet;
int fMiscFlags;
@@ -297,7 +297,7 @@
return fDatatypeValidator;
}
-inline int SchemaElementDecl::getEnclosingScope() const
+inline unsigned int SchemaElementDecl::getEnclosingScope() const
{
return fEnclosingScope;
}
@@ -373,7 +373,7 @@
fDatatypeValidator = newDatatypeValidator;
}
-inline void SchemaElementDecl::setEnclosingScope(const int newEnclosingScope)
+inline void SchemaElementDecl::setEnclosingScope(const unsigned int newEnclosingScope)
{
fEnclosingScope = newEnclosingScope;
}
Modified: xerces/c/trunk/src/xercesc/validators/schema/TraverseSchema.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/validators/schema/TraverseSchema.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/validators/schema/TraverseSchema.cpp (original)
+++ xerces/c/trunk/src/xercesc/validators/schema/TraverseSchema.cpp Fri May 19 11:25:12 2006
@@ -7183,7 +7183,7 @@
SchemaGrammar* aGrammar = fSchemaGrammar;
SchemaElementDecl* elemDecl = baseTypeInfo->elementAt(i);
int elemURI = elemDecl->getURI();
- int elemScope = elemDecl->getEnclosingScope();
+ unsigned int elemScope = elemDecl->getEnclosingScope();
if (elemScope != Grammar::TOP_LEVEL_SCOPE) {
@@ -7228,7 +7228,7 @@
for (unsigned int i = 0; i < elemCount; i++) {
SchemaElementDecl* elemDecl = fromGroup->elementAt(i);
- int elemScope = elemDecl->getEnclosingScope();
+ unsigned int elemScope = elemDecl->getEnclosingScope();
if (elemScope != Grammar::TOP_LEVEL_SCOPE)
{
@@ -7276,7 +7276,7 @@
if (typeInfo) {
- int elemScope = elemDecl->getEnclosingScope();
+ unsigned int elemScope = elemDecl->getEnclosingScope();
if (elemScope != Grammar::TOP_LEVEL_SCOPE) {
Modified: xerces/c/trunk/src/xercesc/validators/schema/XercesGroupInfo.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/validators/schema/XercesGroupInfo.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/validators/schema/XercesGroupInfo.cpp (original)
+++ xerces/c/trunk/src/xercesc/validators/schema/XercesGroupInfo.cpp Fri May 19 11:25:12 2006
@@ -34,7 +34,7 @@
// ---------------------------------------------------------------------------
XercesGroupInfo::XercesGroupInfo(MemoryManager* const manager)
: fCheckElementConsistency(true)
- , fScope(-1)
+ , fScope(Grammar::TOP_LEVEL_SCOPE)
, fNameId(0)
, fNamespaceId(0)
, fContentSpec(0)
@@ -49,7 +49,7 @@
unsigned int groupNamespaceId,
MemoryManager* const manager)
: fCheckElementConsistency(true)
- , fScope(-1)
+ , fScope(Grammar::TOP_LEVEL_SCOPE)
, fNameId(groupNameId)
, fNamespaceId(groupNamespaceId)
, fContentSpec(0)
Modified: xerces/c/trunk/src/xercesc/validators/schema/XercesGroupInfo.hpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/validators/schema/XercesGroupInfo.hpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/validators/schema/XercesGroupInfo.hpp (original)
+++ xerces/c/trunk/src/xercesc/validators/schema/XercesGroupInfo.hpp Fri May 19 11:25:12 2006
@@ -63,7 +63,7 @@
// Getter methods
// -----------------------------------------------------------------------
bool getCheckElementConsistency() const;
- int getScope() const;
+ unsigned int getScope() const;
unsigned int elementCount() const;
ContentSpecNode* getContentSpec() const;
SchemaElementDecl* elementAt(const unsigned int index);
@@ -76,7 +76,7 @@
// -----------------------------------------------------------------------
// Setter methods
// -----------------------------------------------------------------------
- void setScope(const int other);
+ void setScope(const unsigned int other);
void setContentSpec(ContentSpecNode* const other);
void addElement(SchemaElementDecl* const toAdd);
void setLocator(XSDLocator* const aLocator);
@@ -100,7 +100,7 @@
// Private data members
// -----------------------------------------------------------------------
bool fCheckElementConsistency;
- int fScope;
+ unsigned int fScope;
unsigned int fNameId;
unsigned int fNamespaceId;
ContentSpecNode* fContentSpec;
@@ -112,7 +112,7 @@
// ---------------------------------------------------------------------------
// XercesGroupInfo: Getter methods
// ---------------------------------------------------------------------------
-inline int XercesGroupInfo::getScope() const {
+inline unsigned int XercesGroupInfo::getScope() const {
return fScope;
}
@@ -167,7 +167,7 @@
// ---------------------------------------------------------------------------
// XercesGroupInfo: Setter methods
// ---------------------------------------------------------------------------}
-inline void XercesGroupInfo::setScope(const int other) {
+inline void XercesGroupInfo::setScope(const unsigned int other) {
fScope = other;
}
Modified: xerces/c/trunk/src/xercesc/validators/schema/identity/XercesXPath.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/src/xercesc/validators/schema/identity/XercesXPath.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/src/xercesc/validators/schema/identity/XercesXPath.cpp (original)
+++ xerces/c/trunk/src/xercesc/validators/schema/identity/XercesXPath.cpp Fri May 19 11:25:12 2006
@@ -782,7 +782,7 @@
// | NameTest | NodeType | Operator | FunctionName
// | AxisName | Literal | Number | VariableReference
//
- XMLByte chartype = (ch >= 0x80) ? CHARTYPE_NONASCII : fASCIICharMap[ch];
+ XMLByte chartype = (ch >= 0x80) ? (XMLByte)CHARTYPE_NONASCII : fASCIICharMap[ch];
switch (chartype) {
case CHARTYPE_OPEN_PAREN: // '('
Modified: xerces/c/trunk/swig/perl/Xerces.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/swig/perl/Xerces.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/swig/perl/Xerces.cpp (original)
+++ xerces/c/trunk/swig/perl/Xerces.cpp Fri May 19 11:25:12 2006
@@ -8112,6 +8112,66 @@
{
XERCES_CPP_NAMESPACE::XMLUri *arg1 = (XERCES_CPP_NAMESPACE::XMLUri *) (XERCES_CPP_NAMESPACE::XMLUri *)0 ;
XMLCh *arg2 = (XMLCh *) (XMLCh *)0 ;
+ bool arg3 ;
+ bool result;
+ void *argp1 = 0 ;
+ int res1 = 0 ;
+ bool val3 ;
+ int ecode3 = 0 ;
+ int argvi = 0;
+ dXSARGS;
+
+ if ((items < 3) || (items > 3)) {
+ SWIG_croak("Usage: XMLUri_isValidURI(baseURI,uriStr,bAllowSpaces);");
+ }
+ res1 = SWIG_ConvertPtr(ST(0), &argp1,SWIGTYPE_p_XERCES_CPP_NAMESPACE__XMLUri, 0 | 0 );
+ if (!SWIG_IsOK(res1)) {
+ SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "XMLUri_isValidURI" "', argument " "1"" of type '" "XERCES_CPP_NAMESPACE::XMLUri const *const""'");
+ }
+ arg1 = reinterpret_cast< XERCES_CPP_NAMESPACE::XMLUri * >(argp1);
+
+ if (ST(1) == &PL_sv_undef) {
+ SWIG_Perl_NullRef("perl-string",2,"XMLUri_isValidURI");
+ goto fail;
+ } else {
+ // we convert *everything* into a string that isn't undef
+ arg2 = Perl2XMLString(ST(1));
+ }
+
+ ecode3 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
+ if (!SWIG_IsOK(ecode3)) {
+ SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "XMLUri_isValidURI" "', argument " "3"" of type '" "bool""'");
+ }
+ arg3 = static_cast< bool >(val3);
+ {
+ try
+ {
+ result = (bool)XERCES_CPP_NAMESPACE::XMLUri::isValidURI((XERCES_CPP_NAMESPACE::XMLUri const *)arg1,(uint16_t const *)arg2,arg3);
+ }
+ CATCH_XML_EXCEPTION
+ }
+ ST(argvi) = SWIG_From_bool SWIG_PERL_CALL_ARGS_1(static_cast< bool >(result)); argvi++ ;
+
+
+ delete[] arg2;
+
+
+ XSRETURN(argvi);
+ fail:
+
+
+ delete[] arg2;
+
+
+ SWIG_croak_null();
+ }
+}
+
+
+XS(_wrap_XMLUri_isValidURI__SWIG_1) {
+ {
+ XERCES_CPP_NAMESPACE::XMLUri *arg1 = (XERCES_CPP_NAMESPACE::XMLUri *) (XERCES_CPP_NAMESPACE::XMLUri *)0 ;
+ XMLCh *arg2 = (XMLCh *) (XMLCh *)0 ;
bool result;
void *argp1 = 0 ;
int res1 = 0 ;
@@ -8158,7 +8218,67 @@
}
-XS(_wrap_XMLUri_isValidURI__SWIG_1) {
+XS(_wrap_XMLUri_isValidURI__SWIG_2) {
+ {
+ bool arg1 ;
+ XMLCh *arg2 = (XMLCh *) (XMLCh *)0 ;
+ bool arg3 ;
+ bool result;
+ bool val1 ;
+ int ecode1 = 0 ;
+ bool val3 ;
+ int ecode3 = 0 ;
+ int argvi = 0;
+ dXSARGS;
+
+ if ((items < 3) || (items > 3)) {
+ SWIG_croak("Usage: XMLUri_isValidURI(haveBaseURI,uriStr,bAllowSpaces);");
+ }
+ ecode1 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(0), &val1);
+ if (!SWIG_IsOK(ecode1)) {
+ SWIG_exception_fail(SWIG_ArgError(ecode1), "in method '" "XMLUri_isValidURI" "', argument " "1"" of type '" "bool""'");
+ }
+ arg1 = static_cast< bool >(val1);
+
+ if (ST(1) == &PL_sv_undef) {
+ SWIG_Perl_NullRef("perl-string",2,"XMLUri_isValidURI");
+ goto fail;
+ } else {
+ // we convert *everything* into a string that isn't undef
+ arg2 = Perl2XMLString(ST(1));
+ }
+
+ ecode3 = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), &val3);
+ if (!SWIG_IsOK(ecode3)) {
+ SWIG_exception_fail(SWIG_ArgError(ecode3), "in method '" "XMLUri_isValidURI" "', argument " "3"" of type '" "bool""'");
+ }
+ arg3 = static_cast< bool >(val3);
+ {
+ try
+ {
+ result = (bool)XERCES_CPP_NAMESPACE::XMLUri::isValidURI(arg1,(uint16_t const *)arg2,arg3);
+ }
+ CATCH_XML_EXCEPTION
+ }
+ ST(argvi) = SWIG_From_bool SWIG_PERL_CALL_ARGS_1(static_cast< bool >(result)); argvi++ ;
+
+
+ delete[] arg2;
+
+
+ XSRETURN(argvi);
+ fail:
+
+
+ delete[] arg2;
+
+
+ SWIG_croak_null();
+ }
+}
+
+
+XS(_wrap_XMLUri_isValidURI__SWIG_3) {
{
bool arg1 ;
XMLCh *arg2 = (XMLCh *) (XMLCh *)0 ;
@@ -8275,12 +8395,97 @@
}
check_2:
+ if (items == 3) {
+ SWIG_TypeRank _ranki = 0;
+ SWIG_TypeRank _rankm = 0;
+ SWIG_TypeRank _pi = 1;
+ int _v = 0;
+ {
+ void *vptr = 0;
+ int res = SWIG_ConvertPtr(ST(0), &vptr, SWIGTYPE_p_XERCES_CPP_NAMESPACE__XMLUri, 0);
+ _v = SWIG_CheckState(res);
+ }
+ if (!_v) goto check_3;
+ _ranki += _v*_pi;
+ _rankm += _pi;
+ _pi *= SWIG_MAXCASTRANK;
+ {
+ {
+ _v = SvOK(ST(1)) ? 1 : 0;
+ }
+ }
+ if (!_v) goto check_3;
+ _ranki += _v*_pi;
+ _rankm += _pi;
+ _pi *= SWIG_MAXCASTRANK;
+ {
+ {
+ int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
+ _v = SWIG_CheckState(res);
+ }
+ }
+ if (!_v) goto check_3;
+ _ranki += _v*_pi;
+ _rankm += _pi;
+ _pi *= SWIG_MAXCASTRANK;
+ if (!_index || (_ranki < _rank)) {
+ _rank = _ranki; _index = 3;
+ if (_rank == _rankm) goto dispatch;
+ }
+ }
+ check_3:
+
+ if (items == 3) {
+ SWIG_TypeRank _ranki = 0;
+ SWIG_TypeRank _rankm = 0;
+ SWIG_TypeRank _pi = 1;
+ int _v = 0;
+ {
+ {
+ int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(0), NULL);
+ _v = SWIG_CheckState(res);
+ }
+ }
+ if (!_v) goto check_4;
+ _ranki += _v*_pi;
+ _rankm += _pi;
+ _pi *= SWIG_MAXCASTRANK;
+ {
+ {
+ _v = SvOK(ST(1)) ? 1 : 0;
+ }
+ }
+ if (!_v) goto check_4;
+ _ranki += _v*_pi;
+ _rankm += _pi;
+ _pi *= SWIG_MAXCASTRANK;
+ {
+ {
+ int res = SWIG_AsVal_bool SWIG_PERL_CALL_ARGS_2(ST(2), NULL);
+ _v = SWIG_CheckState(res);
+ }
+ }
+ if (!_v) goto check_4;
+ _ranki += _v*_pi;
+ _rankm += _pi;
+ _pi *= SWIG_MAXCASTRANK;
+ if (!_index || (_ranki < _rank)) {
+ _rank = _ranki; _index = 4;
+ if (_rank == _rankm) goto dispatch;
+ }
+ }
+ check_4:
+
dispatch:
switch(_index) {
case 1:
- ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLUri_isValidURI__SWIG_0); return;
- case 2:
++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLUri_isValidURI__SWIG_1); return;
+ case 2:
+ ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLUri_isValidURI__SWIG_3); return;
+ case 3:
+ ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLUri_isValidURI__SWIG_0); return;
+ case 4:
+ ++PL_markstack_ptr; SWIG_CALLXS(_wrap_XMLUri_isValidURI__SWIG_2); return;
}
}
@@ -22133,7 +22338,7 @@
XS(_wrap_SchemaElementDecl_getEnclosingScope) {
{
XERCES_CPP_NAMESPACE::SchemaElementDecl *arg1 = (XERCES_CPP_NAMESPACE::SchemaElementDecl *) 0 ;
- int result;
+ unsigned int result;
void *argp1 = 0 ;
int res1 = 0 ;
int argvi = 0;
@@ -22150,11 +22355,11 @@
{
try
{
- result = (int)((XERCES_CPP_NAMESPACE::SchemaElementDecl const *)arg1)->getEnclosingScope();
+ result = (unsigned int)((XERCES_CPP_NAMESPACE::SchemaElementDecl const *)arg1)->getEnclosingScope();
}
CATCH_XML_EXCEPTION
}
- ST(argvi) = SWIG_From_int SWIG_PERL_CALL_ARGS_1(static_cast< int >(result)); argvi++ ;
+ ST(argvi) = SWIG_From_unsigned_SS_int SWIG_PERL_CALL_ARGS_1(static_cast< unsigned int >(result)); argvi++ ;
XSRETURN(argvi);
fail:
@@ -22584,10 +22789,10 @@
XS(_wrap_SchemaElementDecl_setEnclosingScope) {
{
XERCES_CPP_NAMESPACE::SchemaElementDecl *arg1 = (XERCES_CPP_NAMESPACE::SchemaElementDecl *) 0 ;
- int arg2 ;
+ unsigned int arg2 ;
void *argp1 = 0 ;
int res1 = 0 ;
- int val2 ;
+ unsigned int val2 ;
int ecode2 = 0 ;
int argvi = 0;
dXSARGS;
@@ -22600,11 +22805,11 @@
SWIG_exception_fail(SWIG_ArgError(res1), "in method '" "SchemaElementDecl_setEnclosingScope" "', argument " "1"" of type '" "XERCES_CPP_NAMESPACE::SchemaElementDecl *""'");
}
arg1 = reinterpret_cast< XERCES_CPP_NAMESPACE::SchemaElementDecl * >(argp1);
- ecode2 = SWIG_AsVal_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
+ ecode2 = SWIG_AsVal_unsigned_SS_int SWIG_PERL_CALL_ARGS_2(ST(1), &val2);
if (!SWIG_IsOK(ecode2)) {
- SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SchemaElementDecl_setEnclosingScope" "', argument " "2"" of type '" "int""'");
+ SWIG_exception_fail(SWIG_ArgError(ecode2), "in method '" "SchemaElementDecl_setEnclosingScope" "', argument " "2"" of type '" "unsigned int""'");
}
- arg2 = static_cast< int >(val2);
+ arg2 = static_cast< unsigned int >(val2);
{
try
{
Modified: xerces/c/trunk/tests/src/DOM/DOMMemTest/DOMMemTest.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/tests/src/DOM/DOMMemTest/DOMMemTest.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/tests/src/DOM/DOMMemTest/DOMMemTest.cpp (original)
+++ xerces/c/trunk/tests/src/DOM/DOMMemTest/DOMMemTest.cpp Fri May 19 11:25:12 2006
@@ -36,6 +36,8 @@
bool errorOccurred = false;
+#define UNUSED(x) { if(x!=0); }
+
#define TASSERT(c) tassert((c), __FILE__, __LINE__)
void tassert(bool c, const char *file, int line)
@@ -138,22 +140,31 @@
DOMDocument* doc = DOMImplementationRegistry::getDOMImplementation(X("Core"))->createDocument();
DOMElement* el = doc->createElement(X("Doc02Element"));
+ UNUSED(el); // silence warning
DOMDocumentFragment* frag = doc->createDocumentFragment ();
+ UNUSED(frag); // silence warning
DOMText* text = doc->createTextNode(X("Doc02TextNode"));
+ UNUSED(text); // silence warning
DOMComment* comment = doc->createComment(X("Doc02Comment"));
+ UNUSED(comment); // silence warning
DOMCDATASection* cdataSec = doc->createCDATASection(X("Doc02CDataSection"));
+ UNUSED(cdataSec); // silence warning
DOMDocumentType* docType = doc->createDocumentType(X("Doc02DocumentType"));
+ UNUSED(docType); // silence warning
DOMNotation* notation = doc->createNotation(X("Doc02Notation"));
+ UNUSED(notation); // silence warning
DOMProcessingInstruction* pi = doc->createProcessingInstruction(X("Doc02PITarget"), X("Doc02PIData"));
+ UNUSED(pi); // silence warning
DOMNodeList* nodeList = doc->getElementsByTagName(X("*"));
+ UNUSED(nodeList); // silence warning
doc->release();
}
@@ -176,6 +187,7 @@
rootEl->appendChild(textNode);
DOMNodeList* nodeList = doc->getElementsByTagName(X("*"));
+ UNUSED(nodeList); // silence warning
doc->release();
};
@@ -283,6 +295,7 @@
attr01->setValue(X("Attr04Value1"));
DOMNode* value = attr01->getFirstChild();
+ UNUSED(value); // silence warning
doc->release();
}
@@ -470,6 +483,7 @@
try
{
DOMElement* el = doc->createElement(X("!@@ bad element name"));
+ UNUSED(el); // silence warning
TASSERT(false); // Exception above should prevent us reaching here.
}
catch ( DOMException e)
@@ -851,6 +865,7 @@
try
{
DOMDocument* doc2 = impl->createDocument(X("pubId"), X("foo:docName"), dt);
+ UNUSED(doc2); // silence warning
TASSERT(false); // should not reach here.
}
catch ( DOMException &e)
@@ -1020,6 +1035,7 @@
DOMDocument* doc = impl->createDocument(X("http://document.namespace"), X("foo:docName"), dt);
DOMElement* rootEl = doc->getDocumentElement();
+ UNUSED(rootEl); // silence warning
//
// CreateAttributeNS
@@ -1416,7 +1432,7 @@
char tempchar[4000];
for(i=0;i<20000;i++)
{
- sprintf(tempchar, "time is %i\n",XMLPlatformUtils::getCurrentMillis());
+ sprintf(tempchar, "time is %lu\n",XMLPlatformUtils::getCurrentMillis());
int len = strlen(tempchar);
for (int j = len; j < 4000-len; j++)
tempchar[j] = 'a';
@@ -1426,7 +1442,7 @@
DOMText* text = cpXMLDocument->createTextNode(tempStr3);
for(i=0;i<20000;i++)
{
- sprintf(tempchar, "time is %i\n",XMLPlatformUtils::getCurrentMillis());
+ sprintf(tempchar, "time is %lu\n",XMLPlatformUtils::getCurrentMillis());
int len = strlen(tempchar);
for (int j = len; j < 4000-len; j++)
tempchar[j] = 'a';
Modified: xerces/c/trunk/tests/src/DOM/DOMTest/DTest.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/tests/src/DOM/DOMTest/DTest.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/tests/src/DOM/DOMTest/DTest.cpp (original)
+++ xerces/c/trunk/tests/src/DOM/DOMTest/DTest.cpp Fri May 19 11:25:12 2006
@@ -36,6 +36,8 @@
#include <xercesc/util/OutOfMemoryException.hpp>
#include <xercesc/framework/MemBufInputSource.hpp>
+#define UNUSED(x) { if(x!=0); }
+
#define EXCEPTIONSTEST(operation, expectedException, resultFlag, testNum) \
{ \
try \
@@ -631,6 +633,7 @@
//***********Following are for errorTests
DOMDocumentFragment* docDocFragment = doc->createDocumentFragment();
+ UNUSED(docDocFragment); // silence warning
//name + "docTextNode3"
XMLString::copyString(tempStr, name);
@@ -648,10 +651,13 @@
XMLString::transcode("ourEntityNode", tempStr, 3999);
DOMNode* abc2 = doc->getDoctype()->getEntities()->getNamedItem(tempStr); // Get the DOMEntity* node
DOMEntity* docEntity = (DOMEntity*) abc2;
+ UNUSED(docEntity); // silence warning
DOMNode* abc3 = doc->getFirstChild(); // Get the DOMDocumentType* node
DOMDocumentType* docDocType = (DOMDocumentType*) abc3;
+ UNUSED(docDocType); // silence warning
DOMNode* abc4 = doc->getLastChild()->getLastChild()->getLastChild()->getFirstChild();
DOMEntityReference* entityReferenceText = (DOMEntityReference*) abc4;
+ UNUSED(entityReferenceText); // silence warning
//"entityReferenceText information"
XMLString::transcode("entityReferenceText information", tempStr, 3999);
@@ -824,7 +830,7 @@
*
*
*/
-int main(int argc, char **argv)
+int main(int /*argc*/, char **/*argv*/)
{
bool OK = true;
@@ -844,9 +850,6 @@
return -1;
}
- long avgTime = 0;
- long startTime = 0;//****************Time the whole thing for efficiency of DOM implementation
-
// for (int i=0; i< 1000; i++)
// {
// AH Revisit // startTime = System.currentTimeMillis();
@@ -861,6 +864,7 @@
XMLString::transcode("ourEntityNode", tempStr, 3999);
DOMEntity* docEntity = test.createEntity( d, tempStr);
+ UNUSED(docEntity); // silence warning
//Build a branch for entityReference tests
// DOMText* entityChildText = d.createTextNode("entityChildText information"); //
// docEntity->appendChild(entityChildText);
@@ -960,7 +964,6 @@
DOMNode* node;
DOMAttr* attributeNode;
bool T = true;
- bool F = false;
bool OK = true;
// For debugging***** printf("\n testAttr's outputs:\n\n");
@@ -1729,7 +1732,7 @@
DOMTest tests; // What is this for? 'tests' is never used.
//!! Throws INDEX_SIZE_ERR ********************
- EXCEPTIONSTEST(charData->deleteData(-1, 5), DOMException::INDEX_SIZE_ERR, OK, 101 );
+ EXCEPTIONSTEST(charData->deleteData((XMLSize_t)-1, 5), DOMException::INDEX_SIZE_ERR, OK, 101 );
// Test 102 is not an error because the -1 parameter is an unsigned value, and counts
// that exceed the length of the string are allowed.
// EXCEPTIONSTEST(charData->deleteData(2, -1), DOMException::INDEX_SIZE_ERR, OK, 102 );
@@ -1746,7 +1749,7 @@
EXCEPTIONSTEST(charData->replaceData(100, 5 ,tempStr), DOMException::INDEX_SIZE_ERR, OK, 107 );
// EXCEPTIONSTEST(charData->replaceData(2, -1, "Replacement stuff"), DOMException::INDEX_SIZE_ERR, OK, 108 );
- EXCEPTIONSTEST(charData->substringData(-1, 5), DOMException::INDEX_SIZE_ERR, OK, 109 );
+ EXCEPTIONSTEST(charData->substringData((XMLSize_t)-1, 5), DOMException::INDEX_SIZE_ERR, OK, 109 );
EXCEPTIONSTEST(charData->substringData(100, 5), DOMException::INDEX_SIZE_ERR, OK, 110 );
// EXCEPTIONSTEST(charData->substringData(2, -1), DOMException::INDEX_SIZE_ERR, OK, 111 );
@@ -2714,7 +2717,6 @@
DOMElement* element, *element2;
DOMNode* node, *node2;
- const char* attributeCompare[] = {"AnotherFirstElementAttribute", "dFirstElement", "testAttribute"};
const char* elementNames[] = {"dFirstElement", "dTestBody", "dBodyLevel21","dBodyLevel31","dBodyLevel32",
"dBodyLevel22","dBodyLevel33","dBodyLevel34","dBodyLevel23","dBodyLevel24"};
const char* textCompare[] = {"dBodyLevel31'sChildTextNode11",
@@ -4737,10 +4739,13 @@
}
DOMNode* newt2=((DOMText*)t2)->replaceWholeText(s2);
+ UNUSED(newt2); //silence warning
DOMNode* newt3=((DOMText*)t3)->replaceWholeText(s3);
+ UNUSED(newt3); //silence warning
try
{
DOMNode* newt4=((DOMText*)t4)->replaceWholeText(s4);
+ UNUSED(newt4); //silence warning
// ent5 contains a <foo/> node, and cannot be removed
fprintf(stderr, "checking wholeText failed at line %i\n", __LINE__);
return false;
Modified: xerces/c/trunk/tests/src/DOM/Normalizer/Normalizer.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/tests/src/DOM/Normalizer/Normalizer.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/tests/src/DOM/Normalizer/Normalizer.cpp (original)
+++ xerces/c/trunk/tests/src/DOM/Normalizer/Normalizer.cpp Fri May 19 11:25:12 2006
@@ -218,7 +218,7 @@
theOutput->release();
}
-int main(int argc, char **argv) {
+int main(int /*argc*/, char **/*argv*/) {
Normalizer *normalizer = new Normalizer();
Modified: xerces/c/trunk/tests/src/DOM/RangeTest/RangeTest.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/tests/src/DOM/RangeTest/RangeTest.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/tests/src/DOM/RangeTest/RangeTest.cpp (original)
+++ xerces/c/trunk/tests/src/DOM/RangeTest/RangeTest.cpp Fri May 19 11:25:12 2006
@@ -41,6 +41,8 @@
bool errorOccurred = false;
+#define UNUSED(x) { if(x!=0); }
+
#define TASSERT(c) tassert((c), __FILE__, __LINE__)
void tassert(bool c, const char *file, int line)
@@ -60,13 +62,13 @@
errorOccurred = true; \
} \
catch (DOMRangeException &e) { \
- if (e.code != expected_exception) { \
+ if (e.code != (DOMRangeException::RangeExceptionCode)expected_exception) { \
printf(" Wrong RangeException code: %d at line %d\n", e.code, __LINE__); \
errorOccurred = true; \
} \
} \
catch (DOMException &e) { \
- if (e.code != expected_exception) { \
+ if (e.code != (DOMException::ExceptionCode)expected_exception) { \
printf(" Wrong exception code: %d at line %d\n", e.code, __LINE__); \
errorOccurred = true; \
} \
@@ -216,7 +218,7 @@
E12->appendChild(textNode2);
DOMText* E210 = doc->createTextNode(xInsertedText);
-
+ UNUSED(E210); // silence warning
doc->release();
@@ -919,6 +921,7 @@
TASSERT(!XMLString::compareString(newrange->toString(),xabHellocd));
DOMNode* n = newrange->cloneContents();
+ UNUSED(n); // silence warning
DOMNodeList* nol = foo->getChildNodes();
//removing moo
Modified: xerces/c/trunk/tests/src/DOM/Traversal/Traversal.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/tests/src/DOM/Traversal/Traversal.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/tests/src/DOM/Traversal/Traversal.cpp (original)
+++ xerces/c/trunk/tests/src/DOM/Traversal/Traversal.cpp Fri May 19 11:25:12 2006
@@ -41,6 +41,8 @@
bool errorOccurred = false;
+#define UNUSED(x) { if(x!=0); }
+
#define TASSERT(c) tassert((c), __FILE__, __LINE__)
void tassert(bool c, const char *file, int line)
@@ -247,6 +249,7 @@
// all node iterating test
DOMNode* node = doc->getFirstChild();
+ UNUSED(node); // silence warning
unsigned long whatToShow = DOMNodeFilter::SHOW_ALL;
MyFilter* filter = new MyFilter(0);
@@ -304,6 +307,7 @@
//element node iterating test
DOMNode* node = doc->getFirstChild();
+ UNUSED(node); // silence warning
unsigned long whatToShow = DOMNodeFilter::SHOW_ELEMENT;
MyFilter* filter = new MyFilter(DOMNode::ELEMENT_NODE);
@@ -348,6 +352,7 @@
// Text node iterating test
DOMNode* node = doc->getFirstChild();
+ UNUSED(node); // silence warning
unsigned long whatToShow = DOMNodeFilter::SHOW_TEXT;
MyFilter* filter = new MyFilter(DOMNode::TEXT_NODE);
@@ -372,6 +377,7 @@
//CDataSection node itearating test
DOMNode* node = doc->getFirstChild();
+ UNUSED(node); // silence warning
unsigned long whatToShow = DOMNodeFilter::SHOW_CDATA_SECTION;
MyFilter* filter = new MyFilter(DOMNode::CDATA_SECTION_NODE);
@@ -393,6 +399,7 @@
// PI nodes iterating test
DOMNode* node = doc->getFirstChild();
+ UNUSED(node); // silence warning
unsigned long whatToShow = DOMNodeFilter::SHOW_PROCESSING_INSTRUCTION;
MyFilter* filter = new MyFilter(DOMNode::PROCESSING_INSTRUCTION_NODE);
@@ -413,6 +420,7 @@
{
DOMNode* node = doc->getFirstChild();
+ UNUSED(node); // silence warning
unsigned long whatToShow = DOMNodeFilter::SHOW_COMMENT;
MyFilter* filter = new MyFilter(DOMNode::COMMENT_NODE);
Modified: xerces/c/trunk/tests/src/DOM/TypeInfo/TypeInfo.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/tests/src/DOM/TypeInfo/TypeInfo.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/tests/src/DOM/TypeInfo/TypeInfo.cpp (original)
+++ xerces/c/trunk/tests/src/DOM/TypeInfo/TypeInfo.cpp Fri May 19 11:25:12 2006
@@ -30,6 +30,7 @@
#include <iostream.h>
#endif
+#define UNUSED(x) { if(x!=0); }
#define DOMTYPEINFOTEST(info, type, uri, line) \
tmp = XMLString::equals(info->getTypeName(), type) && XMLString::equals(info->getTypeNamespace(), uri);\
@@ -320,6 +321,7 @@
bool passed = true;
DOMNode *docEle = doc->getDocumentElement();
+ UNUSED(docEle); // silence warning
//the eleTest element.
DOMElement *testEle = findElement(X("eleTest"));
@@ -447,6 +449,7 @@
bool passed = true;
DOMNode *docEle = doc->getDocumentElement();
+ UNUSED(docEle); // silence warning
//element simpleDerTest
DOMElement *testEle = (DOMElement *)docEle->getFirstChild()->getNextSibling()->getNextSibling()
@@ -471,6 +474,7 @@
bool passed = true;
DOMNode *docEle = doc->getDocumentElement();
+ UNUSED(docEle); // silence warning
//element complexTest
DOMElement *testEle = findElement(X("complexTest"));
@@ -486,6 +490,7 @@
bool passed = true;
DOMNode *docEle = doc->getDocumentElement();
+ UNUSED(docEle); // silence warning
DOMAttr *testAttr;
//element unionTest
@@ -535,6 +540,7 @@
bool passed = true;
DOMNode *docEle = doc->getDocumentElement();
+ UNUSED(docEle); // silence warning
DOMAttr *testAttr;
@@ -562,6 +568,7 @@
bool passed = true;
DOMNode *docEle = doc->getDocumentElement();
+ UNUSED(docEle); // silence warning
//element xsiTypeTest
DOMElement *testEle = findElement(X("xsiTypeTest"));
@@ -593,6 +600,7 @@
bool passed = true;
DOMNode *docEle = doc->getDocumentElement();
+ UNUSED(docEle); // silence warning
DOMAttr *testAttr;
//element anyTestPartial
@@ -669,6 +677,7 @@
bool passed = true;
DOMNode *docEle = doc->getDocumentElement();
+ UNUSED(docEle); // silence warning
DOMAttr *testAttr;
@@ -780,6 +789,7 @@
bool TypeInfo::combinedTest() {
bool passed = true;
DOMNode *docEle = doc->getDocumentElement();
+ UNUSED(docEle); // silence warning
DOMAttr *testAttr;
DOMElement *testEle = doc->getDocumentElement();
@@ -815,7 +825,7 @@
return (DOMElement *)toTest;
}
-int main(int argc, char **argv)
+int main(int /*argc*/, char **/*argv*/)
{
bool passed = true;
Modified: xerces/c/trunk/tests/src/MemHandlerTest/MemoryMonitor.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/tests/src/MemHandlerTest/MemoryMonitor.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/tests/src/MemHandlerTest/MemoryMonitor.cpp (original)
+++ xerces/c/trunk/tests/src/MemHandlerTest/MemoryMonitor.cpp Fri May 19 11:25:12 2006
@@ -173,7 +173,6 @@
bool doSchema = false;
bool schemaFullChecking = false;
bool doList = false;
- bool errorOccurred = false;
int numReps =1;
int argInd;
Modified: xerces/c/trunk/tests/src/ThreadTest/ThreadTest.cpp
URL: http://svn.apache.org/viewvc/xerces/c/trunk/tests/src/ThreadTest/ThreadTest.cpp?rev=407876&r1=407875&r2=407876&view=diff
==============================================================================
--- xerces/c/trunk/tests/src/ThreadTest/ThreadTest.cpp (original)
+++ xerces/c/trunk/tests/src/ThreadTest/ThreadTest.cpp Fri May 19 11:25:12 2006
@@ -87,7 +87,7 @@
void ThreadFuncs::startThread(ThreadFunc func, void *param)
{
- unsigned long x;
+ int x;
pthread_t tId;
//thread_t tId;
@@ -251,6 +251,7 @@
MemoryManager* gpMemMgr = 0;
XMLGrammarPool* gp = 0;
+#ifdef HELPER_ROUTINES
// Routines which maybe helpful for debugging
static void printString(const XMLCh *str)
{
@@ -302,6 +303,7 @@
}
fflush(stderr);
}
+#endif
//------------------------------------------------------------------------------
//
@@ -670,9 +672,9 @@
// and any attribute names and values.
//
-void ThreadParser::SAX2Handler::startElement(const XMLCh *const uri,
+void ThreadParser::SAX2Handler::startElement(const XMLCh *const /*uri*/,
const XMLCh *const localname,
- const XMLCh *const qname,
+ const XMLCh *const /*qname*/,
const Attributes& attributes)
{
SAX2Instance->addToCheckSum(localname);
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@xerces.apache.org
For additional commands, e-mail: commits-help@xerces.apache.org