You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by dk...@apache.org on 2008/01/08 21:30:22 UTC
svn commit: r610134 - in /incubator/cxf/branches/2.0.x-fixes: ./
rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java
rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
Author: dkulp
Date: Tue Jan 8 12:30:21 2008
New Revision: 610134
URL: http://svn.apache.org/viewvc?rev=610134&view=rev
Log:
Merged revisions 609812 via svnmerge from
https://svn.apache.org/repos/asf/incubator/cxf/trunk
........
r609812 | dkulp | 2008-01-07 18:55:51 -0500 (Mon, 07 Jan 2008) | 2 lines
[CXF-1223, CXF-1276] More fixes for conent encoding issues in conduit, fix issue of partially allowing some bare stuff as wrapped when it shouldn't be.
........
Modified:
incubator/cxf/branches/2.0.x-fixes/ (props changed)
incubator/cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java
incubator/cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
Propchange: incubator/cxf/branches/2.0.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.
Modified: incubator/cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java
URL: http://svn.apache.org/viewvc/incubator/cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java?rev=610134&r1=610133&r2=610134&view=diff
==============================================================================
--- incubator/cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java (original)
+++ incubator/cxf/branches/2.0.x-fixes/rt/core/src/main/java/org/apache/cxf/wsdl11/WSDLServiceBuilder.java Tue Jan 8 12:30:21 2008
@@ -73,6 +73,7 @@
import org.apache.cxf.service.model.UnwrappedOperationInfo;
import org.apache.cxf.transport.DestinationFactory;
import org.apache.cxf.transport.DestinationFactoryManager;
+import org.apache.ws.commons.schema.XmlSchemaComplexContentExtension;
import org.apache.ws.commons.schema.XmlSchemaComplexType;
import org.apache.ws.commons.schema.XmlSchemaElement;
import org.apache.ws.commons.schema.XmlSchemaObject;
@@ -553,8 +554,10 @@
XmlSchemaComplexType xsct = null;
if (inputEl.getSchemaType() instanceof XmlSchemaComplexType) {
+
xsct = (XmlSchemaComplexType)inputEl.getSchemaType();
if (hasAttributes(xsct)
+ || (inputEl.isNillable() && !relaxed)
|| !isWrappableSequence(xsct, inputEl.getQName().getNamespaceURI(),
unwrappedInput, relaxed)) {
passedRule = false;
@@ -573,6 +576,7 @@
if (outputEl != null && outputEl.getSchemaType() instanceof XmlSchemaComplexType) {
xsct = (XmlSchemaComplexType)outputEl.getSchemaType();
if (hasAttributes(xsct)
+ || (outputEl.isNillable() && !relaxed)
|| !isWrappableSequence(xsct, outputEl.getQName().getNamespaceURI(), unwrappedOutput,
relaxed)) {
passedRule = false;
@@ -644,6 +648,12 @@
return ret;
} else if (type.getParticle() == null) {
+ if (type.getContentModel() == null) {
+ return true;
+ }
+ if (type.getContentModel().getContent() instanceof XmlSchemaComplexContentExtension) {
+ return false;
+ }
return true;
}
return false;
Modified: incubator/cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java
URL: http://svn.apache.org/viewvc/incubator/cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java?rev=610134&r1=610133&r2=610134&view=diff
==============================================================================
--- incubator/cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java (original)
+++ incubator/cxf/branches/2.0.x-fixes/rt/transports/http/src/main/java/org/apache/cxf/transport/http/HTTPConduit.java Tue Jan 8 12:30:21 2008
@@ -1926,15 +1926,10 @@
charset = charset.substring(0, charset.indexOf(";"));
}
}
- String enc = connection.getContentEncoding();
- if (charset == null) {
- charset = enc;
- }
-
String normalizedEncoding = HttpHeaderHelper.mapCharset(charset);
if (normalizedEncoding == null) {
String m = new org.apache.cxf.common.i18n.Message("INVALID_ENCODING_MSG",
- LOG, enc).toString();
+ LOG, charset).toString();
LOG.log(Level.WARNING, m);
throw new IOException(m);
}