[
https://issues.apache.org/jira/browse/AXIS2-3179?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Rich Scheuerle resolved AXIS2-3179.
-----------------------------------
Resolution: Fixed
Committed Revision = 573373
> Wrong prefix used (resulting in a duplicate but conflicting declaration) when
> sending fault message.
> ----------------------------------------------------------------------------------------------------
>
> Key: AXIS2-3179
> URL: https://issues.apache.org/jira/browse/AXIS2-3179
> Project: Axis 2.0 (Axis2)
> Issue Type: Bug
> Components: kernel
> Reporter: Rich Scheuerle
> Assignee: Rich Scheuerle
>
> MessageContextBuilder gets the prefix and uri off of the AxisFault's
> faultCode and builds a SOAPFault faultcode.
> The current ordering of the statements can lead to duplicate declarations of
> the soapenv prefix.
> Bill Nagy has supplied the correct ordering:
> String prefix = faultCodeQName.getPrefix();
> String uri = faultCodeQName.getNamespaceURI();
> // Get the specified prefix and uri
> prefix = prefix == null ? "" : prefix;
> uri = uri == null || "" .equals(uri) ?
> fault.getNamespace().getNamespaceURI() : uri;
> // Make sure the prefix and uri are declared on the
> fault, and
> // get the resulting prefix.
> prefix = fault.declareNamespace(uri,
> prefix).getPrefix();
> soapFaultCode = prefix + ":" +
> faultCodeQName.getLocalPart();
> I will commit this simple fix after running tests.
> Thanks,
> Scheu
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]