Use shutdown instead.

This commit is contained in:
Tristan B. Kildaire 2020-05-14 14:03:54 +02:00
parent 95577698b8
commit 1ade3365b1
2 changed files with 3 additions and 34 deletions

View File

@ -346,37 +346,6 @@ public final class BesterConnection : Thread
}
}
/* Send an error report */
public void sendErrorReport(string id)
{
/* Construct the response */
JSONValue statusMessage;
/* Construct the haeder block */
JSONValue headerBlock;
headerBlock["status"] = "bad";
/* Attach the header block */
statusMessage["header"] = headerBlock;
/* Create the payload block */
JSONValue payloadBlock;
payloadBlock["id"] = id;
/* Attach the payload block */
statusMessage["payload"] = payloadBlock;
try
{
/* Send the message */
sendMessage(clientConnection, statusMessage);
}
catch(NetworkException e)
{
debugPrint("Error sending status message");
}
}
/* Send a status message to the client */
public void sendStatus(uint code, JSONValue data)
{
@ -512,7 +481,7 @@ public final class BesterConnection : Thread
sendStatus(2, JSONValue());
/* Stop the read/write loop */
isActive = false;
shutdown();
return;
}
}

View File

@ -222,7 +222,7 @@ public final class HandlerResponse
* SocketOSException to be called.
*/
debugPrint("Attempted interacting with dead socket");
allSuccess=false;
allSuccess = false;
}
}
@ -293,7 +293,7 @@ public final class HandlerResponse
{
/* TODO: Be more specific with the above exception type */
debugPrint("Error whilst sending payload to server: " ~ e.toString());
allSuccess=false;
allSuccess = false;
}
}