Don't crash if we couldn't generate a certificate
Another crash workaround for #334. Even though this null check should be left there, since getCertificate() may return null for whatever reason.
This commit is contained in:
parent
d8b4fc403d
commit
478ff88a82
@ -123,6 +123,10 @@ public class WifiStateChangeService extends Service {
|
|||||||
// the fingerprint for the local repo's signing key
|
// the fingerprint for the local repo's signing key
|
||||||
LocalRepoKeyStore localRepoKeyStore = LocalRepoKeyStore.get(context);
|
LocalRepoKeyStore localRepoKeyStore = LocalRepoKeyStore.get(context);
|
||||||
Certificate localCert = localRepoKeyStore.getCertificate();
|
Certificate localCert = localRepoKeyStore.getCertificate();
|
||||||
|
// We were not able to generate/get a certificate
|
||||||
|
if (localCert == null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
FDroidApp.repo.fingerprint = Utils.calcFingerprint(localCert);
|
FDroidApp.repo.fingerprint = Utils.calcFingerprint(localCert);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
Loading…
x
Reference in New Issue
Block a user