mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-04-19 16:19:33 +01:00
Fix narrow race around generation of some ACI keys.
This commit is contained in:
@@ -296,8 +296,19 @@ public class ApplicationDependencyProvider implements ApplicationDependencies.Pr
|
||||
throw new IllegalStateException("No PNI set!");
|
||||
}
|
||||
|
||||
boolean needsPreKeyJob = false;
|
||||
|
||||
if (!SignalStore.account().hasAciIdentityKey()) {
|
||||
SignalStore.account().generateAciIdentityKeyIfNecessary();
|
||||
needsPreKeyJob = true;
|
||||
}
|
||||
|
||||
if (!SignalStore.account().hasPniIdentityKey()) {
|
||||
SignalStore.account().generatePniIdentityKeyIfNecessary();
|
||||
needsPreKeyJob = true;
|
||||
}
|
||||
|
||||
if (needsPreKeyJob) {
|
||||
CreateSignedPreKeyJob.enqueueIfNeeded();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user