Author: dkulp Date: Tue Sep 11 19:54:26 2012 New Revision: 1383586 URL: http://svn.apache.org/viewvc?rev=1383586&view=rev Log: Merged revisions 1378308 via git cherry-pick from https://svn.apache.org/repos/asf/cxf/branches/2.5.x-fixes
........ r1378308 | dkulp | 2012-08-28 16:26:48 -0400 (Tue, 28 Aug 2012) | 18 lines Merged revisions 1375643 via git cherry-pick from https://svn.apache.org/repos/asf/cxf/branches/2.6.x-fixes ........ r1375643 | dkulp | 2012-08-21 12:13:43 -0400 (Tue, 21 Aug 2012) | 10 lines Merged revisions 1374058 via git cherry-pick from https://svn.apache.org/repos/asf/cxf/trunk ........ r1374058 | dkulp | 2012-08-16 17:05:25 -0400 (Thu, 16 Aug 2012) | 2 lines Bus can be optional for this ........ ........ ........ Modified: cxf/branches/2.4.x-fixes/api/src/main/java/org/apache/cxf/wsdl/EndpointReferenceUtils.java Modified: cxf/branches/2.4.x-fixes/api/src/main/java/org/apache/cxf/wsdl/EndpointReferenceUtils.java URL: http://svn.apache.org/viewvc/cxf/branches/2.4.x-fixes/api/src/main/java/org/apache/cxf/wsdl/EndpointReferenceUtils.java?rev=1383586&r1=1383585&r2=1383586&view=diff ============================================================================== --- cxf/branches/2.4.x-fixes/api/src/main/java/org/apache/cxf/wsdl/EndpointReferenceUtils.java (original) +++ cxf/branches/2.4.x-fixes/api/src/main/java/org/apache/cxf/wsdl/EndpointReferenceUtils.java Tue Sep 11 19:54:26 2012 @@ -485,13 +485,15 @@ public final class EndpointReferenceUtil if (StringUtils.isEmpty(wsdlLocation)) { return ""; } - WSDLManager manager = bus.getExtension(WSDLManager.class); - if (manager != null) { - try { - Definition def = manager.getDefinition(wsdlLocation); - return def.getTargetNamespace(); - } catch (WSDLException e) { - //ignore + if (bus != null) { + WSDLManager manager = bus.getExtension(WSDLManager.class); + if (manager != null) { + try { + Definition def = manager.getDefinition(wsdlLocation); + return def.getTargetNamespace(); + } catch (WSDLException e) { + //ignore + } } } return "";
