taylor 2004/05/24 21:36:52
Modified:
components/registry/src/java/org/apache/jetspeed/components/portletregistry
PortletRegistryHelper.java
Log:
fix NPE in registry help
PR:
Obtained from:
Submitted by:
Reviewed by:
CVS: ----------------------------------------------------------------------
CVS: PR:
CVS: If this change addresses a PR in the problem report tracking
CVS: database, then enter the PR number(s) here.
CVS: Obtained from:
CVS: If this change has been taken from another system, such as NCSA,
CVS: then name the system in this line, otherwise delete it.
CVS: Submitted by:
CVS: If this code has been contributed to Apache by someone else; i.e.,
CVS: they sent us a patch or a new module, then include their name/email
CVS: address here. If this is your work then delete this line.
CVS: Reviewed by:
CVS: If we are doing pre-commit code reviews and someone else has
CVS: reviewed your changes, include their name(s) here.
CVS: If you have not had it reviewed then delete this line.
Revision Changes Path
1.2 +5 -1
jakarta-jetspeed-2/components/registry/src/java/org/apache/jetspeed/components/portletregistry/PortletRegistryHelper.java
Index: PortletRegistryHelper.java
===================================================================
RCS file:
/home/cvs/jakarta-jetspeed-2/components/registry/src/java/org/apache/jetspeed/components/portletregistry/PortletRegistryHelper.java,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- PortletRegistryHelper.java 8 May 2004 17:55:25 -0000 1.1
+++ PortletRegistryHelper.java 25 May 2004 04:36:52 -0000 1.2
@@ -53,7 +53,11 @@
*/
private static int splitUniqueName(String uniqueName)
{
- int split =
uniqueName.indexOf(PortletRegistryComponentImpl.PORTLET_UNIQUE_NAME_SEPARATOR);
+ int split = 0;
+ if (null != uniqueName)
+ {
+ split =
uniqueName.indexOf(PortletRegistryComponentImpl.PORTLET_UNIQUE_NAME_SEPARATOR);
+ }
if (split < 1)
{
throw new IllegalArgumentException(
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]