RongNetworkStateChangeReceiver$RefreshIpReachableTask.smali
.class Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver$RefreshIpReachableTask;
.super Ljava/lang/Object;
.source "RongNetworkStateChangeReceiver.java"
# interfaces
.implements Ljava/util/concurrent/Callable;
# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
value = Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;
.end annotation
.annotation system Ldalvik/annotation/InnerClass;
accessFlags = 0x0
name = "RefreshIpReachableTask"
.end annotation
.annotation system Ldalvik/annotation/Signature;
value = {
"Ljava/lang/Object;",
"Ljava/util/concurrent/Callable<",
"Ljava/lang/Object;",
">;"
}
.end annotation
# instance fields
.field final synthetic this$0:Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;
# direct methods
.method constructor <init>(Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;)V
.registers 2
.line 1
iput-object p1, p0, Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver$RefreshIpReachableTask;->this$0:Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;
invoke-direct {p0}, Ljava/lang/Object;-><init>()V
return-void
.end method
# virtual methods
.method public call()Ljava/lang/Object;
.registers 6
.line 1
new-instance v0, Ljava/net/InetSocketAddress;
const-string v1, "2001:4860:4860::8888"
const/16 v2, 0x1bb
invoke-direct {v0, v1, v2}, Ljava/net/InetSocketAddress;-><init>(Ljava/lang/String;I)V
.line 2
new-instance v1, Ljava/net/InetSocketAddress;
const-string v2, "180.76.76.76"
const/16 v3, 0x50
invoke-direct {v1, v2, v3}, Ljava/net/InetSocketAddress;-><init>(Ljava/lang/String;I)V
const/4 v2, 0x0
const/4 v3, 0x0
.line 3
:try_start_14
new-instance v4, Ljava/net/DatagramSocket;
invoke-direct {v4}, Ljava/net/DatagramSocket;-><init>()V
:try_end_19
.catch Ljava/net/SocketException; {:try_start_14 .. :try_end_19} :catch_23
.catchall {:try_start_14 .. :try_end_19} :catchall_20
.line 4
:try_start_19
invoke-virtual {v4, v1}, Ljava/net/DatagramSocket;->connect(Ljava/net/SocketAddress;)V
:try_end_1c
.catch Ljava/net/SocketException; {:try_start_19 .. :try_end_1c} :catch_24
.catchall {:try_start_19 .. :try_end_1c} :catchall_71
.line 5
:goto_1c
invoke-virtual {v4}, Ljava/net/DatagramSocket;->close()V
goto :goto_2c
:catchall_20
move-exception v0
move-object v4, v2
goto :goto_72
:catch_23
move-object v4, v2
.line 6
:catch_24
:try_start_24
iget-object v1, p0, Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver$RefreshIpReachableTask;->this$0:Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;
# setter for: Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;->isIPv4Reachable:Z
invoke-static {v1, v3}, Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;->access$002(Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;Z)Z
:try_end_29
.catchall {:try_start_24 .. :try_end_29} :catchall_71
if-eqz v4, :cond_2c
goto :goto_1c
.line 7
:cond_2c
:goto_2c
:try_start_2c
new-instance v1, Ljava/net/DatagramSocket;
invoke-direct {v1}, Ljava/net/DatagramSocket;-><init>()V
:try_end_31
.catch Ljava/net/SocketException; {:try_start_2c .. :try_end_31} :catch_3f
.catchall {:try_start_2c .. :try_end_31} :catchall_3d
.line 8
:try_start_31
invoke-virtual {v1, v0}, Ljava/net/DatagramSocket;->connect(Ljava/net/SocketAddress;)V
:try_end_34
.catch Ljava/net/SocketException; {:try_start_31 .. :try_end_34} :catch_3b
.catchall {:try_start_31 .. :try_end_34} :catchall_38
.line 9
invoke-virtual {v1}, Ljava/net/DatagramSocket;->close()V
goto :goto_49
:catchall_38
move-exception v0
move-object v4, v1
goto :goto_6b
:catch_3b
move-object v4, v1
goto :goto_3f
:catchall_3d
move-exception v0
goto :goto_6b
.line 10
:catch_3f
:goto_3f
:try_start_3f
iget-object v0, p0, Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver$RefreshIpReachableTask;->this$0:Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;
# setter for: Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;->isIPv6Reachable:Z
invoke-static {v0, v3}, Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;->access$102(Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;Z)Z
:try_end_44
.catchall {:try_start_3f .. :try_end_44} :catchall_3d
if-eqz v4, :cond_49
.line 11
invoke-virtual {v4}, Ljava/net/DatagramSocket;->close()V
:cond_49
:goto_49
const/4 v0, 0x2
.line 12
new-array v0, v0, [Ljava/lang/Object;
iget-object v1, p0, Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver$RefreshIpReachableTask;->this$0:Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;
# getter for: Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;->isIPv4Reachable:Z
invoke-static {v1}, Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;->access$000(Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;)Z
move-result v1
invoke-static {v1}, Ljava/lang/Boolean;->valueOf(Z)Ljava/lang/Boolean;
move-result-object v1
aput-object v1, v0, v3
const/4 v1, 0x1
iget-object v3, p0, Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver$RefreshIpReachableTask;->this$0:Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;
# getter for: Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;->isIPv6Reachable:Z
invoke-static {v3}, Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;->access$100(Lio/rong/imlib/httpdns/RongNetworkStateChangeReceiver;)Z
move-result v3
invoke-static {v3}, Ljava/lang/Boolean;->valueOf(Z)Ljava/lang/Boolean;
move-result-object v3
aput-object v3, v0, v1
const-string v1, "isIPv4Reachable(%s), isIPv6Reachable(%s)"
invoke-static {v1, v0}, Lio/rong/imlib/httpdns/Logger;->printLog(Ljava/lang/String;[Ljava/lang/Object;)V
return-object v2
:goto_6b
if-eqz v4, :cond_70
.line 13
invoke-virtual {v4}, Ljava/net/DatagramSocket;->close()V
:cond_70
throw v0
:catchall_71
move-exception v0
:goto_72
if-eqz v4, :cond_77
.line 14
invoke-virtual {v4}, Ljava/net/DatagramSocket;->close()V
:cond_77
goto :goto_79
:goto_78
throw v0
:goto_79
goto :goto_78
.end method