Return-Path: Delivered-To: apmail-myfaces-dev-archive@www.apache.org Received: (qmail 68221 invoked from network); 24 Mar 2010 18:39:51 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 24 Mar 2010 18:39:51 -0000 Received: (qmail 64445 invoked by uid 500); 24 Mar 2010 18:39:51 -0000 Delivered-To: apmail-myfaces-dev-archive@myfaces.apache.org Received: (qmail 64400 invoked by uid 500); 24 Mar 2010 18:39:51 -0000 Mailing-List: contact dev-help@myfaces.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: "MyFaces Development" Delivered-To: mailing list dev@myfaces.apache.org Received: (qmail 64391 invoked by uid 99); 24 Mar 2010 18:39:51 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 24 Mar 2010 18:39:51 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 24 Mar 2010 18:39:48 +0000 Received: from brutus.apache.org (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 604D3234C4E3 for ; Wed, 24 Mar 2010 18:39:27 +0000 (UTC) Message-ID: <325789885.467791269455967393.JavaMail.jira@brutus.apache.org> Date: Wed, 24 Mar 2010 18:39:27 +0000 (UTC) From: =?utf-8?Q?Matthias_We=C3=9Fendorf_=28JIRA=29?= To: dev@myfaces.apache.org Subject: [jira] Commented: (TRINIDAD-1751) NPE if User-Agent header is missing In-Reply-To: <67067443.178511268235688321.JavaMail.jira@brutus.apache.org> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/TRINIDAD-1751?page=3Dcom.atlass= ian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=3D1= 2849343#action_12849343 ]=20 Matthias We=C3=9Fendorf commented on TRINIDAD-1751: ---------------------------------------------- You can test the NULL case with curl =3D> curl -A "" url_to_trinidad_app By default almost all "user-agents" do submit an user-agent string, since t= hey play nice... > NPE if User-Agent header is missing > ----------------------------------- > > Key: TRINIDAD-1751 > URL: https://issues.apache.org/jira/browse/TRINIDAD-1751 > Project: MyFaces Trinidad > Issue Type: Bug > Components: Components > Affects Versions: 1.2.13-core=20 > Reporter: Harald Kuhn > Assignee: Matthias We=C3=9Fendorf > Fix For: 1.2.14-core , 2.0.0.3-core > > Attachments: TRINIDAD-1751.patch > > > After a upgrade from trinidad 1.2.11 to Trinidad 1.2.13 I get a NullPoint= erException from one of our monitoring scripts. > Caused by: java.lang.NullPointerException > at org.apache.myfaces.trinidadinternal.agent.AgentFactoryImpl._po= pulateAgentImpl(AgentFactoryImpl.java:115) > at org.apache.myfaces.trinidadinternal.agent.AgentFactoryImpl.cre= ateAgent(AgentFactoryImpl.java:65) > at org.apache.myfaces.trinidadinternal.context.RequestContextImpl= .getAgent(RequestContextImpl.java:695) > at org.apache.myfaces.trinidadinternal.renderkit.core.CoreRenderK= it.chooseRenderKit(CoreRenderKit.java:139) > at org.apache.myfaces.trinidadinternal.renderkit.CoreRenderKitFac= tory.getRenderKit(CoreRenderKitFactory.java:52) > While tracking this issue further down it showed that the monitoring scri= pt doesn't send a User-Agent header along with the request. > This case isn't considered any more in AgentFactoryImpl._populateAgentImp= l(). > The version from Trinidad 1.2.11 used to have the following code block: > if (userAgent =3D=3D null) > { > _populateUnknownAgentImpl(null, agent); > return; > } > it looks has been changed/removed in this rev: > http://svn.apache.org/viewvc?view=3Drevision&revision=3D820104 --=20 This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.