Uploaded image for project: 'Minecraft: Java Edition'
  1. Minecraft: Java Edition
  2. MC-168669

RconClient.RconClient(ServerInterface, String, Socket) exception handling is faulty

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • None
    • 1.15.1
    • None
    • Plausible
    • Networking
    • Low
    • Platform

      The bug

      The constructor net.minecraft.server.rcon.thread.RconClient.RconClient(ServerInterface, String, Socket) (Mojang name) handles the exception from Socket.setSoTimeout incorrectly:

      RconClient(ServerInterface serverInterface, String string, Socket socket) {
          super(serverInterface, "RCON Client");
          this.client = socket;
          try {
              this.client.setSoTimeout(0);
          }
          catch (Exception exception) {
              this.running = false;
          }
          this.rconPassword = string;
          this.info("Rcon connection from: " + socket.getInetAddress());
      }
      

      Setting this.running = false; here has no effect since false is the default value and is only set once start() is called.

            Unassigned Unassigned
            marcono1234 [Mod] Marcono1234
            Votes:
            4 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              CHK: