mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-13 11:19:04 +01:00
Raised minimum Android version to 2.3 (API 9). #23
This commit is contained in:
@@ -1,25 +1,19 @@
|
||||
package org.briarproject.system;
|
||||
|
||||
import android.os.Build;
|
||||
|
||||
import java.io.DataOutputStream;
|
||||
import java.io.IOException;
|
||||
|
||||
import android.annotation.SuppressLint;
|
||||
import android.os.Build;
|
||||
|
||||
class AndroidSeedProvider extends LinuxSeedProvider {
|
||||
|
||||
@Override
|
||||
@SuppressLint("NewApi")
|
||||
void writeToEntropyPool(DataOutputStream out) throws IOException {
|
||||
out.writeInt(android.os.Process.myPid());
|
||||
out.writeInt(android.os.Process.myTid());
|
||||
out.writeInt(android.os.Process.myUid());
|
||||
String fingerprint = Build.FINGERPRINT;
|
||||
if (fingerprint != null) out.writeUTF(fingerprint);
|
||||
if (Build.VERSION.SDK_INT >= 9) {
|
||||
String serial = Build.SERIAL;
|
||||
if (serial != null) out.writeUTF(serial);
|
||||
}
|
||||
if (Build.FINGERPRINT != null) out.writeUTF(Build.FINGERPRINT);
|
||||
if (Build.SERIAL != null) out.writeUTF(Build.SERIAL);
|
||||
super.writeToEntropyPool(out);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user