Weather/smali_classes4/com/tencent/smtt/sdk/a.smali
2021-05-10 10:13:34 +02:00

239 lines
4.6 KiB
Smali

.class public Lcom/tencent/smtt/sdk/a;
.super Ljava/lang/Object;
# static fields
.field public static a:I = 0x258
.field private static b:I
# direct methods
.method static constructor <clinit>()V
.locals 0
return-void
.end method
.method public static a()I
.locals 6
sget v0, Lcom/tencent/smtt/sdk/a;->b:I
if-lez v0, :cond_0
sget v0, Lcom/tencent/smtt/sdk/a;->b:I
return v0
:cond_0
const-string v0, "/proc/meminfo"
const/4 v1, 0x0
const/4 v2, 0x0
:try_start_0
new-instance v3, Ljava/io/FileReader;
invoke-direct {v3, v0}, Ljava/io/FileReader;-><init>(Ljava/lang/String;)V
new-instance v0, Ljava/io/BufferedReader;
const/16 v4, 0x2000
invoke-direct {v0, v3, v4}, Ljava/io/BufferedReader;-><init>(Ljava/io/Reader;I)V
:try_end_0
.catch Ljava/io/IOException; {:try_start_0 .. :try_end_0} :catch_4
.catch Ljava/lang/Throwable; {:try_start_0 .. :try_end_0} :catch_3
.catchall {:try_start_0 .. :try_end_0} :catchall_0
:cond_1
:try_start_1
invoke-virtual {v0}, Ljava/io/BufferedReader;->readLine()Ljava/lang/String;
move-result-object v1
if-eqz v1, :cond_2
const-string v3, "MemTotal:"
invoke-virtual {v1, v3}, Ljava/lang/String;->indexOf(Ljava/lang/String;)I
move-result v3
const/4 v4, -0x1
if-eq v4, v3, :cond_1
const-string v4, "MemTotal:"
invoke-virtual {v4}, Ljava/lang/String;->length()I
move-result v4
add-int/2addr v3, v4
invoke-virtual {v1, v3}, Ljava/lang/String;->substring(I)Ljava/lang/String;
move-result-object v1
invoke-virtual {v1}, Ljava/lang/String;->trim()Ljava/lang/String;
move-result-object v1
if-eqz v1, :cond_2
invoke-virtual {v1}, Ljava/lang/String;->length()I
move-result v3
if-eqz v3, :cond_2
const-string v3, "k"
invoke-virtual {v1, v3}, Ljava/lang/String;->contains(Ljava/lang/CharSequence;)Z
move-result v3
if-eqz v3, :cond_2
const-string v3, "k"
invoke-virtual {v1, v3}, Ljava/lang/String;->indexOf(Ljava/lang/String;)I
move-result v3
invoke-virtual {v1, v2, v3}, Ljava/lang/String;->substring(II)Ljava/lang/String;
move-result-object v1
invoke-virtual {v1}, Ljava/lang/String;->trim()Ljava/lang/String;
move-result-object v1
invoke-static {v1}, Ljava/lang/Integer;->parseInt(Ljava/lang/String;)I
move-result v1
div-int/lit16 v1, v1, 0x400
:try_end_1
.catch Ljava/io/IOException; {:try_start_1 .. :try_end_1} :catch_2
.catch Ljava/lang/Throwable; {:try_start_1 .. :try_end_1} :catch_1
.catchall {:try_start_1 .. :try_end_1} :catchall_1
move v2, v1
:cond_2
:try_start_2
invoke-virtual {v0}, Ljava/io/BufferedReader;->close()V
:try_end_2
.catch Ljava/io/IOException; {:try_start_2 .. :try_end_2} :catch_0
goto :goto_2
:catch_0
move-exception v0
invoke-virtual {v0}, Ljava/io/IOException;->printStackTrace()V
goto :goto_2
:catch_1
move-exception v1
goto :goto_0
:catch_2
move-exception v1
goto :goto_1
:catchall_0
move-exception v0
move-object v5, v1
move-object v1, v0
move-object v0, v5
goto :goto_3
:catch_3
move-exception v0
move-object v5, v1
move-object v1, v0
move-object v0, v5
:goto_0
:try_start_3
invoke-virtual {v1}, Ljava/lang/Throwable;->printStackTrace()V
:try_end_3
.catchall {:try_start_3 .. :try_end_3} :catchall_1
if-eqz v0, :cond_3
:try_start_4
invoke-virtual {v0}, Ljava/io/BufferedReader;->close()V
:try_end_4
.catch Ljava/io/IOException; {:try_start_4 .. :try_end_4} :catch_0
goto :goto_2
:catch_4
move-exception v0
move-object v5, v1
move-object v1, v0
move-object v0, v5
:goto_1
:try_start_5
invoke-virtual {v1}, Ljava/io/IOException;->printStackTrace()V
:try_end_5
.catchall {:try_start_5 .. :try_end_5} :catchall_1
if-eqz v0, :cond_3
:try_start_6
invoke-virtual {v0}, Ljava/io/BufferedReader;->close()V
:try_end_6
.catch Ljava/io/IOException; {:try_start_6 .. :try_end_6} :catch_0
:cond_3
:goto_2
sput v2, Lcom/tencent/smtt/sdk/a;->b:I
sget v0, Lcom/tencent/smtt/sdk/a;->b:I
return v0
:catchall_1
move-exception v1
:goto_3
if-eqz v0, :cond_4
:try_start_7
invoke-virtual {v0}, Ljava/io/BufferedReader;->close()V
:try_end_7
.catch Ljava/io/IOException; {:try_start_7 .. :try_end_7} :catch_5
goto :goto_4
:catch_5
move-exception v0
invoke-virtual {v0}, Ljava/io/IOException;->printStackTrace()V
:cond_4
:goto_4
throw v1
.end method