apkfuckery/com.discord/smali/com/crashlytics/android/CrashlyticsInitProvider.smali
2020-04-27 22:53:11 +02:00

363 lines
8.1 KiB
Smali

.class public Lcom/crashlytics/android/CrashlyticsInitProvider;
.super Landroid/content/ContentProvider;
.source "CrashlyticsInitProvider.java"
# annotations
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Lcom/crashlytics/android/CrashlyticsInitProvider$a;
}
.end annotation
# direct methods
.method public constructor <init>()V
.locals 0
invoke-direct {p0}, Landroid/content/ContentProvider;-><init>()V
return-void
.end method
# virtual methods
.method public a(Landroid/content/Context;Lv/a/a/a/p/b/r;Lcom/crashlytics/android/CrashlyticsInitProvider$a;)Z
.locals 1
invoke-virtual {p2, p1}, Lv/a/a/a/p/b/r;->a(Landroid/content/Context;)Z
move-result p2
if-eqz p2, :cond_0
check-cast p3, Le/h/a/b;
invoke-virtual {p3, p1}, Le/h/a/b;->a(Landroid/content/Context;)Z
move-result p1
return p1
:cond_0
const-string p2, "io.fabric.auto_initialize"
const-string p3, "bool"
invoke-static {p1, p2, p3}, Lv/a/a/a/p/b/j;->a(Landroid/content/Context;Ljava/lang/String;Ljava/lang/String;)I
move-result p2
if-nez p2, :cond_1
const/4 p1, 0x0
goto :goto_0
:cond_1
invoke-virtual {p1}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;
move-result-object p1
invoke-virtual {p1, p2}, Landroid/content/res/Resources;->getBoolean(I)Z
move-result p1
if-eqz p1, :cond_2
invoke-static {}, Lv/a/a/a/f;->a()Lv/a/a/a/c;
move-result-object p2
const-string p3, "Fabric"
const/4 v0, 0x3
invoke-virtual {p2, p3, v0}, Lv/a/a/a/c;->a(Ljava/lang/String;I)Z
move-result p2
if-eqz p2, :cond_2
const/4 p2, 0x0
const-string v0, "Found Fabric auto-initialization flag for joint Firebase/Fabric customers"
invoke-static {p3, v0, p2}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
:cond_2
:goto_0
return p1
.end method
.method public final a(Landroid/content/Context;)[Lv/a/a/a/l;
.locals 6
const-string v0, "Fabric"
const/4 v1, 0x0
const/4 v2, 0x1
:try_start_0
invoke-virtual {p1}, Landroid/content/Context;->getPackageManager()Landroid/content/pm/PackageManager;
move-result-object v3
invoke-virtual {p1}, Landroid/content/Context;->getPackageName()Ljava/lang/String;
move-result-object p1
const/16 v4, 0x80
invoke-virtual {v3, p1, v4}, Landroid/content/pm/PackageManager;->getApplicationInfo(Ljava/lang/String;I)Landroid/content/pm/ApplicationInfo;
move-result-object p1
iget-object p1, p1, Landroid/content/pm/ApplicationInfo;->metaData:Landroid/os/Bundle;
if-eqz p1, :cond_0
const-string v3, "firebase_crashlytics_ndk_enabled"
invoke-virtual {p1, v3, v1}, Landroid/os/Bundle;->getBoolean(Ljava/lang/String;Z)Z
move-result p1
:try_end_0
.catch Landroid/content/pm/PackageManager$NameNotFoundException; {:try_start_0 .. :try_end_0} :catch_0
if-eqz p1, :cond_0
const/4 p1, 0x1
goto :goto_0
:catch_0
move-exception p1
invoke-static {}, Lv/a/a/a/f;->a()Lv/a/a/a/c;
move-result-object v3
const/4 v4, 0x3
invoke-virtual {v3, v0, v4}, Lv/a/a/a/c;->a(Ljava/lang/String;I)Z
move-result v3
if-eqz v3, :cond_0
const-string v3, "Unable to get PackageManager while determining if Crashlytics NDK should be initialized"
invoke-static {v0, v3, p1}, Landroid/util/Log;->d(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
:cond_0
const/4 p1, 0x0
:goto_0
new-instance v3, Le/h/a/a;
invoke-direct {v3}, Le/h/a/a;-><init>()V
if-eqz p1, :cond_2
:try_start_1
invoke-static {}, Lv/a/a/a/f;->a()Lv/a/a/a/c;
move-result-object p1
const-string v4, "Crashlytics is initializing NDK crash reporter."
const/4 v5, 0x4
invoke-virtual {p1, v0, v5}, Lv/a/a/a/c;->a(Ljava/lang/String;I)Z
move-result p1
if-eqz p1, :cond_1
const/4 p1, 0x0
invoke-static {v0, v4, p1}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
:cond_1
const/4 p1, 0x2
new-array p1, p1, [Lv/a/a/a/l;
aput-object v3, p1, v1
new-instance v4, Le/h/a/f/c;
invoke-direct {v4}, Le/h/a/f/c;-><init>()V
aput-object v4, p1, v2
:try_end_1
.catchall {:try_start_1 .. :try_end_1} :catchall_0
return-object p1
:catchall_0
move-exception p1
invoke-static {}, Lv/a/a/a/f;->a()Lv/a/a/a/c;
move-result-object v4
const/4 v5, 0x6
invoke-virtual {v4, v0, v5}, Lv/a/a/a/c;->a(Ljava/lang/String;I)Z
move-result v4
if-eqz v4, :cond_2
const-string v4, "Crashlytics failed to initialize NDK crash reporting. Attempting to intialize SDK..."
invoke-static {v0, v4, p1}, Landroid/util/Log;->e(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
:cond_2
new-array p1, v2, [Lv/a/a/a/l;
aput-object v3, p1, v1
return-object p1
.end method
.method public delete(Landroid/net/Uri;Ljava/lang/String;[Ljava/lang/String;)I
.locals 0
const/4 p1, 0x0
return p1
.end method
.method public getType(Landroid/net/Uri;)Ljava/lang/String;
.locals 0
const/4 p1, 0x0
return-object p1
.end method
.method public insert(Landroid/net/Uri;Landroid/content/ContentValues;)Landroid/net/Uri;
.locals 0
const/4 p1, 0x0
return-object p1
.end method
.method public onCreate()Z
.locals 5
invoke-virtual {p0}, Landroid/content/ContentProvider;->getContext()Landroid/content/Context;
move-result-object v0
new-instance v1, Lv/a/a/a/p/b/r;
invoke-direct {v1}, Lv/a/a/a/p/b/r;-><init>()V
new-instance v2, Le/h/a/b;
invoke-direct {v2}, Le/h/a/b;-><init>()V
invoke-virtual {p0, v0, v1, v2}, Lcom/crashlytics/android/CrashlyticsInitProvider;->a(Landroid/content/Context;Lv/a/a/a/p/b/r;Lcom/crashlytics/android/CrashlyticsInitProvider$a;)Z
move-result v1
const/4 v2, 0x0
const/4 v3, 0x4
const-string v4, "CrashlyticsInitProvider"
if-eqz v1, :cond_1
:try_start_0
invoke-virtual {v0}, Landroid/content/Context;->getApplicationContext()Landroid/content/Context;
move-result-object v1
invoke-virtual {p0, v1}, Lcom/crashlytics/android/CrashlyticsInitProvider;->a(Landroid/content/Context;)[Lv/a/a/a/l;
move-result-object v1
invoke-static {v0, v1}, Lv/a/a/a/f;->a(Landroid/content/Context;[Lv/a/a/a/l;)Lv/a/a/a/f;
invoke-static {}, Lv/a/a/a/f;->a()Lv/a/a/a/c;
move-result-object v0
const-string v1, "CrashlyticsInitProvider initialization successful"
invoke-virtual {v0, v4, v3}, Lv/a/a/a/c;->a(Ljava/lang/String;I)Z
move-result v0
if-eqz v0, :cond_2
invoke-static {v4, v1, v2}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
:try_end_0
.catch Ljava/lang/IllegalStateException; {:try_start_0 .. :try_end_0} :catch_0
goto :goto_0
:catch_0
invoke-static {}, Lv/a/a/a/f;->a()Lv/a/a/a/c;
move-result-object v0
invoke-virtual {v0, v4, v3}, Lv/a/a/a/c;->a(Ljava/lang/String;I)Z
move-result v0
if-eqz v0, :cond_0
const-string v0, "CrashlyticsInitProvider initialization unsuccessful"
invoke-static {v4, v0, v2}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
:cond_0
const/4 v0, 0x0
return v0
:cond_1
invoke-static {}, Lv/a/a/a/f;->a()Lv/a/a/a/c;
move-result-object v0
invoke-virtual {v0, v4, v3}, Lv/a/a/a/c;->a(Ljava/lang/String;I)Z
move-result v0
if-eqz v0, :cond_2
const-string v0, "CrashlyticsInitProvider skipping initialization"
invoke-static {v4, v0, v2}, Landroid/util/Log;->i(Ljava/lang/String;Ljava/lang/String;Ljava/lang/Throwable;)I
:cond_2
:goto_0
const/4 v0, 0x1
return v0
.end method
.method public query(Landroid/net/Uri;[Ljava/lang/String;Ljava/lang/String;[Ljava/lang/String;Ljava/lang/String;)Landroid/database/Cursor;
.locals 0
const/4 p1, 0x0
return-object p1
.end method
.method public update(Landroid/net/Uri;Landroid/content/ContentValues;Ljava/lang/String;[Ljava/lang/String;)I
.locals 0
const/4 p1, 0x0
return p1
.end method