MT Manager v2.15.3版本的 MD5 值为:34ea5286e529d87838c6cae0a2220d93

以下内容为反编译后的 C3029.java 源代码,内容仅作参考


package l;

import android.app.Service;
import android.net.Uri;
import com.alipay.sdk.m.l.a;
import java.io.IOException;
import java.lang.ref.WeakReference;
import java.net.ServerSocket;

public final class C3029 extends Thread {

    public C11449 f9102;

    public ServerSocket f9103;

    public final WeakReference f9104;

    public final boolean m8559() {
        return this.f9103 != null;
    }

    public final synchronized void m8560() {
        final ServerSocket serverSocket = this.f9103;
        if (serverSocket != null) {
            this.f9103 = null;
            C13776.f41822.execute(new Runnable() {
                @Override
                public final void run() {
                    try {
                        serverSocket.close();
                    } catch (IOException e) {
                        throw new RuntimeException(e);
                    }
                }
            });
        }
    }

    @Override
    public final void run() {
        Service service;
        WeakReference weakReference = this.f9104;
        try {
            this.f9103 = new ServerSocket(0);
            while (!isInterrupted()) {
                new RunnableC7755(this.f9103.accept(), this.f9102);
            }
            C5263.m13085(this.f9102);
            try {
                ServerSocket serverSocket = this.f9103;
                if (serverSocket != null) {
                    serverSocket.close();
                    this.f9103 = null;
                }
            } catch (IOException unused) {
            }
            service = (Service) weakReference.get();
            if (service == null) {
                return;
            }
        } catch (Exception unused2) {
            C5263.m13085(this.f9102);
            try {
                ServerSocket serverSocket2 = this.f9103;
                if (serverSocket2 != null) {
                    serverSocket2.close();
                    this.f9103 = null;
                }
            } catch (IOException unused3) {
            }
            service = (Service) weakReference.get();
            if (service == null) {
                return;
            }
        } catch (Throwable th) {
            C5263.m13085(this.f9102);
            try {
                ServerSocket serverSocket3 = this.f9103;
                if (serverSocket3 != null) {
                    serverSocket3.close();
                    this.f9103 = null;
                }
            } catch (IOException unused4) {
            }
            Service service2 = (Service) weakReference.get();
            if (service2 != null) {
                service2.stopSelf();
                throw th;
            }
            throw th;
        }
        service.stopSelf();
    }

    public final Uri m8558(C11449 c11449) {
        C11449 c114492 = this.f9102;
        String str = c11449.f33556;
        if (c114492 == null || !c114492.f33556.equals(str)) {
            final C11449 c114493 = this.f9102;
            if (c114493 != null) {
                C13776.f41822.execute(new Runnable() {
                    @Override
                    public final void run() {
                        C5263.m13085(C11449.this);
                    }
                });
            }
            this.f9102 = c11449;
        }
        return new Uri.Builder().scheme(a.r).encodedAuthority("127.0.0.1:" + this.f9103.getLocalPort()).path(str + "/" + c11449.f33552).build();
    }

    public C3029(Service service) {
        this.f9104 = new WeakReference(service);
        setDaemon(true);
        start();
    }
}