Skip to content
Permalink
Browse files

[JENKINS-15156] AbstractProject.builds accessed by Maven & matrix mod…

…ule builds before onLoad or onCreatedFromScratch called.

Seem to need to keep the deprecated no-arg RunMap initializer though it is unclear to me how it could work.
  • Loading branch information
jglick committed Feb 7, 2013
1 parent cb07748 commit 37bf35b5dbb0ccdc34ad0c3643a0802c17e232dc
Showing with 2 additions and 2 deletions.
  1. +2 −2 core/src/main/java/hudson/model/AbstractProject.java
@@ -162,7 +162,8 @@
* {@link Run#getPreviousBuild()}
*/
@Restricted(NoExternalUse.class)
protected transient RunMap<R> builds;
@SuppressWarnings("deprecation") // [JENKINS-15156] builds accessed before onLoad or onCreatedFromScratch called
protected transient RunMap<R> builds = new RunMap<R>();

/**
* The quiet period. Null to delegate to the system default.
@@ -269,7 +270,6 @@ public synchronized void save() throws IOException {
@Override
public void onCreatedFromScratch() {
super.onCreatedFromScratch();
assert builds == null;
builds = createBuildRunMap();
// solicit initial contributions, especially from TransientProjectActionFactory
updateTransientActions();

0 comments on commit 37bf35b

Please sign in to comment.
You can’t perform that action at this time.