提交 e429b697 编写于 作者: R Richard Mortimer 提交者: Kohsuke Kawaguchi

[FIXED JENKINS-15499] HistoryWidget/entry.jelly throws NullPointerException

Wrap history iterable to hide class implementation details.
Jelly was getting confused by the history underlying class being implemented
as an extension of Map
上级 80b7a499
......@@ -63,6 +63,9 @@ Upcoming changes</a>
<div id="rc" style="display:none;"><!--=BEGIN=-->
<h3><a name=v1.491>What's new in 1.491</a> <!--=DATE=--></h3>
<ul class=image>
<li class='major bug'>
HistoryWidget/entry.jelly throws NullPointerException
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-15499">issue 15499</a>)
<li class="major bug">
<code>ArrayIndexOutOfBoundsException</code> or <code>StringIndexOutOfBoundsException</code> launching processes such as Mercurial polling. (Regression in 1.489.)
(<a href="https://issues.jenkins-ci.org/browse/JENKINS-15733">issue 15733</a>)
......
......@@ -26,6 +26,8 @@ package hudson.widgets;
import hudson.Functions;
import hudson.model.ModelObject;
import hudson.model.Run;
import hudson.util.Iterators;
import org.kohsuke.stapler.Header;
import org.kohsuke.stapler.HttpResponses;
import org.kohsuke.stapler.Stapler;
......@@ -133,7 +135,7 @@ public class HistoryWidget<O extends ModelObject,T> extends Widget {
return updateFirstTransientBuildKey(lst);
}
} else
return updateFirstTransientBuildKey(baseList);
return updateFirstTransientBuildKey(Iterators.wrap(baseList));
}
public boolean isTrimmed() {
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册