cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r790647 - in /cxf/branches/2.2.x-fixes: ./ rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapBindingFactory.java
Date Thu, 02 Jul 2009 16:25:03 GMT
Author: dkulp
Date: Thu Jul  2 16:25:03 2009
New Revision: 790647

URL: http://svn.apache.org/viewvc?rev=790647&view=rev
Log:
Merged revisions 790638 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r790638 | dkulp | 2009-07-02 12:19:11 -0400 (Thu, 02 Jul 2009) | 1 line
  
  [CXF-2327] Add some guards around local parts in QName constructions
........

Modified:
    cxf/branches/2.2.x-fixes/   (props changed)
    cxf/branches/2.2.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapBindingFactory.java

Propchange: cxf/branches/2.2.x-fixes/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Thu Jul  2 16:25:03 2009
@@ -1 +1 @@
-/cxf/trunk:782728-782730,783097,783294,783396,784059,784181-784184,784893,784895,785279-785282,785468,785621,785624,785651,785734,785866,786142,786271-786272,786395,786512,786514,786582-786583,786638,786647,786850,787200,787269,787277-787279,787290-787291,787305,787323,787366,787849,788030,788060,788187,788444,788451,788703,788752,788774,788819-788820,789013,789371,789387,789420,789527-789530,789704-789705,789788,789811,789896-789901,790074,790094,790134,790188,790294,790553,790637
+/cxf/trunk:782728-782730,783097,783294,783396,784059,784181-784184,784893,784895,785279-785282,785468,785621,785624,785651,785734,785866,786142,786271-786272,786395,786512,786514,786582-786583,786638,786647,786850,787200,787269,787277-787279,787290-787291,787305,787323,787366,787849,788030,788060,788187,788444,788451,788703,788752,788774,788819-788820,789013,789371,789387,789420,789527-789530,789704-789705,789788,789811,789896-789901,790074,790094,790134,790188,790294,790553,790637-790638

Propchange: cxf/branches/2.2.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: cxf/branches/2.2.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapBindingFactory.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.2.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapBindingFactory.java?rev=790647&r1=790646&r2=790647&view=diff
==============================================================================
--- cxf/branches/2.2.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapBindingFactory.java
(original)
+++ cxf/branches/2.2.x-fixes/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/SoapBindingFactory.java
Thu Jul  2 16:25:03 2009
@@ -515,6 +515,11 @@
             if (StringUtils.isEmpty(partNameFilter)
                 || part.getName().equals(partNameFilter)) {
             
+                if (StringUtils.isEmpty(part.getName())) {
+                    throw new RuntimeException("Problem with WSDL: part element in message
"
+                                               + msg.getQName().getLocalPart() 
+                                               + " does not specify a name.");
+                }
                 QName pqname = new QName(minfo.getName().getNamespaceURI(), part.getName());
                 MessagePartInfo pi = minfo.getMessagePart(pqname);
                 if (pi != null
@@ -601,6 +606,11 @@
             for (SoapHeader header : headers) {
                 SoapHeaderInfo headerInfo = new SoapHeaderInfo();
                 headerInfo.setUse(header.getUse());
+                if (StringUtils.isEmpty(header.getPart())) {
+                    throw new RuntimeException("Problem with WSDL: soap:header element in
operation "
+                                               + boi.getName().getLocalPart() 
+                                               + " does not specify a part.");
+                }
                 MessagePartInfo part = msg.getMessagePart(new QName(msg.getName().getNamespaceURI(),

                                                                     header.getPart()));
                 if (part != null && header.getMessage() != null
@@ -681,6 +691,12 @@
                     attParts = new LinkedList<MessagePartInfo>();
                 }
 
+                if (StringUtils.isEmpty(partName)) {
+                    throw new RuntimeException("Problem with WSDL: mime content element in
operation "
+                                               + bmsg.getBindingOperation().getName().getLocalPart()

+                                               + " does not specify a part.");
+                }
+
                 MessagePartInfo mpi =
                     msg.getMessagePart(new QName(msg.getName().getNamespaceURI(),
                                                  partName));
@@ -703,9 +719,16 @@
 
                 SoapHeaderInfo headerInfo = new SoapHeaderInfo();
                 headerInfo.setUse(header.getUse());
+                
+                if (StringUtils.isEmpty(header.getPart())) {
+                    throw new RuntimeException("Problem with WSDL: soap:header element in
operation "
+                                               + bmsg.getBindingOperation().getName().getLocalPart()

+                                               + " does not specify a part.");
+                }
+                
                 MessagePartInfo mpi =
-                    msg.getMessagePart(new QName(msg.getName().getNamespaceURI(), header
-                                .getPart()));
+                    msg.getMessagePart(new QName(msg.getName().getNamespaceURI(), 
+                                                 header.getPart()));
                 
                 if (mpi != null && header.getMessage() != null
                     && !mpi.getMessageInfo().getName().equals(header.getMessage()))
{



Mime
View raw message