mx4j/src/core/javax/management/relation RelationService.java,1.32,1.33
Jeremy Boynes <[email protected]> Sun, 13 Feb 2005 20:42:50 +0000
| Newsgroups | gmane.comp.java.mx4j.cvs |
|---|---|
| Message-ID | <[email protected]> |
Update of /cvsroot/mx4j/mx4j/src/core/javax/management/relation
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv12267/src/core/javax/management/relation
Modified Files:
RelationService.java
Log Message:
Fix for [ 1121960 ] findRelationsOfType must throw RelationTypeNotFoundException
Index: RelationService.java
===================================================================
RCS file: /cvsroot/mx4j/mx4j/src/core/javax/management/relation/RelationService.java,v
retrieving revision 1.32
retrieving revision 1.33
diff -C2 -d -r1.32 -r1.33
*** RelationService.java 13 Feb 2005 20:33:49 -0000 1.32
--- RelationService.java 13 Feb 2005 20:42:47 -0000 1.33
***************
*** 1716,1727 ****
if (logger.isEnabledFor(Logger.DEBUG)) logger.debug("finding relations matching relationTypeName: " + relationTypeName);
List relationIdList = getRelationIds(relationTypeName);
! List result = new ArrayList();
! if (relationIdList != null)
! {
! // no need to clone read only method
! result = relationIdList;
! }
! return result;
}
--- 1716,1726 ----
if (logger.isEnabledFor(Logger.DEBUG)) logger.debug("finding relations matching relationTypeName: " + relationTypeName);
+ // throws RelationTypeNotFoundException if not found
+ getRelationType(relationTypeName);
+
List relationIdList = getRelationIds(relationTypeName);
! if (relationIdList == null) return new ArrayList();
!
! return new ArrayList(relationIdList);
}
-------------------------------------------------------
SF email is sponsored by - The IT Product Guide
Read honest & candid reviews on hundreds of IT Products from real users.
Discover which products truly live up to the hype. Start reading now.
http://ads.osdn.com/?ad_id=6595&alloc_id=14396&op=click