mirror of
https://github.com/apache/struts.git
synced 2026-08-07 07:37:20 +00:00
Fix NPE when PARSE_CONTENT parameter not in context
WW-2398 git-svn-id: https://svn.apache.org/repos/asf/struts/struts2/trunk@628302 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
+3
-1
@@ -109,8 +109,10 @@ public abstract class AbstractRemoteBean extends ClosingUIBean implements Remote
|
||||
addParameter("parseContent", findValue(parseContent, Boolean.class));
|
||||
else
|
||||
addParameter("parseContent", true);
|
||||
|
||||
Boolean parseContent = (Boolean)stack.getContext().get(Head.PARSE_CONTENT);
|
||||
boolean generateId = (parseContent != null ? !parseContent : false);
|
||||
|
||||
boolean generateId = !(Boolean)stack.getContext().get(Head.PARSE_CONTENT);
|
||||
addParameter("pushId", generateId);
|
||||
if ((this.id == null || this.id.length() == 0) && generateId) {
|
||||
// resolves Math.abs(Integer.MIN_VALUE) issue reported by FindBugs
|
||||
|
||||
Reference in New Issue
Block a user