Fix NullPointerException

git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@2193 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
This commit is contained in:
Derek Hulley 2006-01-25 09:09:23 +00:00
parent cca8a75096
commit d7964671b4

View File

@ -77,7 +77,7 @@ public class AppliedPatchImpl implements AppliedPatch
}
public void setDescription(String description)
{
if (description.length() > 1024)
if (description != null && description.length() > 1024)
{
// truncate as necessary
description = (description.substring(0, 1020) + "...");
@ -155,7 +155,7 @@ public class AppliedPatchImpl implements AppliedPatch
}
public void setReport(String report)
{
if (report.length() > 1024)
if (report != null && report.length() > 1024)
{
// truncate as necessary
report = (report.substring(0, 1020) + "...");