apkfuckery/com.discord/smali_classes2/b0/k/f.smali
2019-12-21 02:41:59 +01:00

151 lines
2.9 KiB
Smali

.class public final Lb0/k/f;
.super Ljava/lang/RuntimeException;
.source "OnErrorThrowable.java"
# annotations
.annotation system Ldalvik/annotation/MemberClasses;
value = {
Lb0/k/f$a;
}
.end annotation
# static fields
.field public static final serialVersionUID:J = -0x7e77a2d646dfd3eL
# instance fields
.field public final hasValue:Z
.field public final value:Ljava/lang/Object;
# direct methods
.method public static a(Ljava/lang/Throwable;Ljava/lang/Object;)Ljava/lang/Throwable;
.locals 5
if-nez p0, :cond_0
new-instance p0, Ljava/lang/NullPointerException;
invoke-direct {p0}, Ljava/lang/NullPointerException;-><init>()V
:cond_0
const/4 v0, 0x0
const/4 v2, 0x0
move-object v1, p0
:goto_0
invoke-virtual {v1}, Ljava/lang/Throwable;->getCause()Ljava/lang/Throwable;
move-result-object v3
const/16 v4, 0x19
if-eqz v3, :cond_2
add-int/lit8 v3, v2, 0x1
if-lt v2, v4, :cond_1
new-instance v1, Ljava/lang/RuntimeException;
const-string v2, "Stack too deep to get final cause"
invoke-direct {v1, v2}, Ljava/lang/RuntimeException;-><init>(Ljava/lang/String;)V
goto :goto_1
:cond_1
invoke-virtual {v1}, Ljava/lang/Throwable;->getCause()Ljava/lang/Throwable;
move-result-object v1
move v2, v3
goto :goto_0
:cond_2
:goto_1
instance-of v2, v1, Lb0/k/f$a;
if-eqz v2, :cond_3
check-cast v1, Lb0/k/f$a;
invoke-virtual {v1}, Lb0/k/f$a;->a()Ljava/lang/Object;
move-result-object v1
if-ne v1, p1, :cond_3
return-object p0
:cond_3
new-instance v1, Lb0/k/f$a;
invoke-direct {v1, p1}, Lb0/k/f$a;-><init>(Ljava/lang/Object;)V
new-instance p1, Ljava/util/HashSet;
invoke-direct {p1}, Ljava/util/HashSet;-><init>()V
const/4 v2, 0x0
move-object v0, p0
:goto_2
invoke-virtual {v0}, Ljava/lang/Throwable;->getCause()Ljava/lang/Throwable;
move-result-object v3
if-eqz v3, :cond_6
add-int/lit8 v3, v2, 0x1
if-lt v2, v4, :cond_4
goto :goto_4
:cond_4
invoke-virtual {v0}, Ljava/lang/Throwable;->getCause()Ljava/lang/Throwable;
move-result-object v0
invoke-virtual {v0}, Ljava/lang/Throwable;->getCause()Ljava/lang/Throwable;
move-result-object v2
invoke-interface {p1, v2}, Ljava/util/Set;->contains(Ljava/lang/Object;)Z
move-result v2
if-eqz v2, :cond_5
goto :goto_3
:cond_5
invoke-virtual {v0}, Ljava/lang/Throwable;->getCause()Ljava/lang/Throwable;
move-result-object v2
invoke-interface {p1, v2}, Ljava/util/Set;->add(Ljava/lang/Object;)Z
move v2, v3
goto :goto_2
:cond_6
:goto_3
:try_start_0
invoke-virtual {v0, v1}, Ljava/lang/Throwable;->initCause(Ljava/lang/Throwable;)Ljava/lang/Throwable;
:try_end_0
.catchall {:try_start_0 .. :try_end_0} :catchall_0
:catchall_0
:goto_4
return-object p0
.end method