Author: alessio.soldano(a)jboss.com
Date: 2008-01-17 05:15:03 -0500 (Thu, 17 Jan 2008)
New Revision: 5487
Modified:
framework/trunk/src/main/java/org/jboss/wsf/framework/deployment/EndpointRecordProcessorDeploymentAspect.java
Log:
[JBWS-1956] Preventing NPE when no processor list is configured
Modified:
framework/trunk/src/main/java/org/jboss/wsf/framework/deployment/EndpointRecordProcessorDeploymentAspect.java
===================================================================
---
framework/trunk/src/main/java/org/jboss/wsf/framework/deployment/EndpointRecordProcessorDeploymentAspect.java 2008-01-17
09:45:29 UTC (rev 5486)
+++
framework/trunk/src/main/java/org/jboss/wsf/framework/deployment/EndpointRecordProcessorDeploymentAspect.java 2008-01-17
10:15:03 UTC (rev 5487)
@@ -58,18 +58,21 @@
for (Endpoint ep : dep.getService().getEndpoints())
{
List<RecordProcessor> processorList = new
LinkedList<RecordProcessor>();
- for (RecordProcessor pr : processors)
+ if (processors != null)
{
- try
+ for (RecordProcessor pr : processors)
{
- RecordProcessor clone = (RecordProcessor)pr.clone();
- registerRecordProcessor(clone, ep);
- processorList.add(clone);
+ try
+ {
+ RecordProcessor clone = (RecordProcessor)pr.clone();
+ registerRecordProcessor(clone, ep);
+ processorList.add(clone);
+ }
+ catch (CloneNotSupportedException ex)
+ {
+ throw new RuntimeException(ex);
+ }
}
- catch (CloneNotSupportedException ex)
- {
- throw new RuntimeException(ex);
- }
}
ep.setRecordProcessors(processorList);
}
Show replies by date