Skip to content

Commit

Permalink
[JENKINS-12598] Prevent NPE if a user has no password set for their c…
Browse files Browse the repository at this point in the history
…vsroot
  • Loading branch information
mc1arke committed Jun 1, 2012
1 parent 1db398a commit fdeb19e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/main/java/hudson/scm/CvsRepository.java
Expand Up @@ -259,6 +259,6 @@ public Object readResolve() {
repositoryItems.add(new CvsRepositoryItem(entry.getKey(), entry.getValue().toArray(new CvsModule[entry.getValue().size()])));
}

return new CvsRepository(cvsRoot, passwordRequired, password.getPlainText(), repositoryItems, Arrays.asList(excludedRegions), compressionLevel);
return new CvsRepository(cvsRoot, passwordRequired, null == password ? null : password.getPlainText(), repositoryItems, Arrays.asList(excludedRegions), compressionLevel);
}
}

0 comments on commit fdeb19e

Please sign in to comment.