Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Merge pull request #5 from Arzie/master
Fix for JENKINS-13160
  • Loading branch information
abayer committed Sep 6, 2013
2 parents 805ab15 + 8716c62 commit 9bfdeb3
Showing 1 changed file with 6 additions and 2 deletions.
Expand Up @@ -28,6 +28,7 @@
import hudson.scm.PollingResult;
import hudson.scm.SCM;
import hudson.scm.ChangeLogParser;
import hudson.scm.NullChangeLogParser;
import hudson.scm.SCMDescriptor;
import hudson.scm.SCMRevisionState;
import static hudson.scm.PollingResult.BUILD_NOW;
Expand Down Expand Up @@ -184,8 +185,11 @@ private boolean calcChangeLog(AbstractBuild<?,?> parentBuild, File changelogFile
@Override
public ChangeLogParser createChangeLogParser() {
AbstractProject<?,?> p = getContainingProject();
final AbstractBuild lastBuild = p.getLastBuild();

AbstractBuild lastBuild = null;
if (p != null) {
lastBuild = p.getLastBuild();
}

try {
return resolve(getParamParentJobName(lastBuild)).getParent().getProject().getScm().createChangeLogParser();
} catch (ResolvedFailedException e) {
Expand Down

0 comments on commit 9bfdeb3

Please sign in to comment.