Return-Path: X-Original-To: apmail-struts-issues-archive@minotaur.apache.org Delivered-To: apmail-struts-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id AF0A81111E for ; Wed, 21 May 2014 12:19:38 +0000 (UTC) Received: (qmail 73168 invoked by uid 500); 21 May 2014 12:19:38 -0000 Delivered-To: apmail-struts-issues-archive@struts.apache.org Received: (qmail 73134 invoked by uid 500); 21 May 2014 12:19:38 -0000 Mailing-List: contact issues-help@struts.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@struts.apache.org Delivered-To: mailing list issues@struts.apache.org Received: (qmail 73121 invoked by uid 99); 21 May 2014 12:19:38 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 21 May 2014 12:19:38 +0000 Date: Wed, 21 May 2014 12:19:38 +0000 (UTC) From: "Lukasz Lenart (JIRA)" To: issues@struts.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Updated] (WW-4350) OgnlValueStack causes race condition MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/WW-4350?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Lukasz Lenart updated WW-4350: ------------------------------ Fix Version/s: 2.3.18 > OgnlValueStack causes race condition > ------------------------------------ > > Key: WW-4350 > URL: https://issues.apache.org/jira/browse/WW-4350 > Project: Struts 2 > Issue Type: Bug > Components: Core Actions, Value Stack > Affects Versions: 2.3.16.1 > Reporter: Sergey Gromov > Fix For: 2.3.18 > > > _com.opensymphony.xwork2.ognl.accessor.CompoundRootAccessor.callMethod_ is not thread safe because of unsynchronized reads and writes to HashMap: > {code} > private static Map invalidMethods = new HashMap(); > ... > public Object callMethod(Map context, Object target, String name, Object[] objects) throws MethodFailedException { > ... > if ((argTypes == null) || !invalidMethods.containsKey(mc)) { > ... > invalidMethods.put(mc, Boolean.TRUE); > ... > } > ... > } > {code} > Propose to use _ConcurrentHashMap_ -- This message was sent by Atlassian JIRA (v6.2#6252)