38 lines
1.4 KiB
Java
38 lines
1.4 KiB
Java
package com.unity3d.player;
|
|
|
|
import android.os.Build;
|
|
import java.lang.Thread;
|
|
|
|
/* loaded from: classes2.dex */
|
|
final class m implements Thread.UncaughtExceptionHandler {
|
|
private volatile Thread.UncaughtExceptionHandler a;
|
|
|
|
m() {
|
|
}
|
|
|
|
final synchronized boolean a() {
|
|
boolean z;
|
|
Thread.UncaughtExceptionHandler defaultUncaughtExceptionHandler = Thread.getDefaultUncaughtExceptionHandler();
|
|
if (defaultUncaughtExceptionHandler == this) {
|
|
z = false;
|
|
} else {
|
|
this.a = defaultUncaughtExceptionHandler;
|
|
Thread.setDefaultUncaughtExceptionHandler(this);
|
|
z = true;
|
|
}
|
|
return z;
|
|
}
|
|
|
|
@Override // java.lang.Thread.UncaughtExceptionHandler
|
|
public final synchronized void uncaughtException(Thread thread, Throwable th) {
|
|
try {
|
|
Error error = new Error(String.format("FATAL EXCEPTION [%s]\n", thread.getName()) + String.format("Unity version : %s\n", "2018.3.0f2") + String.format("Device model : %s %s\n", Build.MANUFACTURER, Build.MODEL) + String.format("Device fingerprint: %s\n", Build.FINGERPRINT));
|
|
error.setStackTrace(new StackTraceElement[0]);
|
|
error.initCause(th);
|
|
this.a.uncaughtException(thread, error);
|
|
} catch (Throwable unused) {
|
|
this.a.uncaughtException(thread, th);
|
|
}
|
|
}
|
|
}
|