Return-Path: Delivered-To: apmail-cocoon-dev-archive@www.apache.org Received: (qmail 52574 invoked from network); 1 Mar 2006 19:04:49 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 1 Mar 2006 19:04:49 -0000 Received: (qmail 55900 invoked by uid 500); 1 Mar 2006 19:05:30 -0000 Delivered-To: apmail-cocoon-dev-archive@cocoon.apache.org Received: (qmail 55819 invoked by uid 500); 1 Mar 2006 19:05:30 -0000 Mailing-List: contact dev-help@cocoon.apache.org; run by ezmlm Precedence: bulk list-help: list-unsubscribe: List-Post: Reply-To: dev@cocoon.apache.org List-Id: Delivered-To: mailing list dev@cocoon.apache.org Received: (qmail 55793 invoked by uid 99); 1 Mar 2006 19:05:30 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received: from [192.87.106.226] (HELO ajax.apache.org) (192.87.106.226) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 01 Mar 2006 11:05:28 -0800 Received: from ajax.apache.org (ajax.apache.org [127.0.0.1]) by ajax.apache.org (Postfix) with ESMTP id A7E3B183 for ; Wed, 1 Mar 2006 20:05:06 +0100 (CET) Message-ID: <466818790.1141239906685.JavaMail.jira@ajax.apache.org> Date: Wed, 1 Mar 2006 20:05:06 +0100 (CET) From: "Eric Meyer (JIRA)" To: dev@cocoon.apache.org Subject: [jira] Closed: (COCOON-1785) I18nMessage - null parameter values causes NPE In-Reply-To: <1486728741.1141145322017.JavaMail.jira@ajax.apache.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N [ http://issues.apache.org/jira/browse/COCOON-1785?page=all ] Eric Meyer closed COCOON-1785: ------------------------------ Resolution: Fixed Thanks, Antonio. --Eric > I18nMessage - null parameter values causes NPE > ---------------------------------------------- > > Key: COCOON-1785 > URL: http://issues.apache.org/jira/browse/COCOON-1785 > Project: Cocoon > Type: Bug > Components: Blocks: Forms > Versions: 2.1.8, 2.1.9-dev (current SVN) > Reporter: Eric Meyer > Assignee: Antonio Gallardo > Attachments: I18nMessageNPE.txt > > Putting a null in a parameter value causes an NPE when creating the SAX events > java.lang.NullPointerException > at org.apache.cocoon.forms.util.I18nMessage.toSAX(I18nMessage.java:128) > at org.apache.cocoon.forms.validation.ValidationError.generateSaxFragment(ValidationError.java:85) > at org.apache.cocoon.forms.formmodel.Field.generateItemSaxFragment(Field.java:453) > at org.apache.cocoon.forms.formmodel.AbstractWidget.generateSaxFragment(AbstractWidget.java:498) > at org.apache.cocoon.forms.generation.JXMacrosHelper.generateWidget(JXMacrosHelper.java:292) > Note: this NPE then causes the Ajax transformer to go wonky for all users in all sessions. I'm still digging into that one. > I am attaching a patch (license granted to ASF) that allows null parameter values (using String.valueOf(parameters[i]) so that nulls are turned into "null". -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira