Browse Source

Merge "Fix NPE in HttpAuthMethod"

tags/v4.2.0.201601211800-r
Christian Halstrick 8 years ago
parent
commit
6dfad98d72

+ 2
- 1
org.eclipse.jgit/src/org/eclipse/jgit/transport/HttpAuthMethod.java View File

@@ -219,7 +219,8 @@ abstract class HttpAuthMethod {
if (credentialsProvider.supports(u, p)
&& credentialsProvider.get(uri, u, p)) {
username = u.getValue();
password = new String(p.getValue());
char[] v = p.getValue();
password = (v == null) ? null : new String(p.getValue());
p.clear();
} else
return false;

Loading…
Cancel
Save