Reverted changes to remot driver because some settings, e.g. highlight mode, stopped working.
This commit is contained in:
parent
0009d90a68
commit
ca0e3b5987
@ -45,28 +45,17 @@ class driver(remoteDriver):
|
||||
continue
|
||||
if self.fenrirSock in r:
|
||||
client_sock, client_addr = self.fenrirSock.accept()
|
||||
response = "ERROR: Failed to process command\n"
|
||||
try:
|
||||
rawdata = client_sock.recv(8129)
|
||||
data = rawdata.decode("utf-8").rstrip().lstrip()
|
||||
if data:
|
||||
# Process the command and get response
|
||||
result = self.env['runtime']['remoteManager'].handleRemoteIncommingWithResponse(data)
|
||||
if result['success']:
|
||||
response = f"OK: {result['message']}\n"
|
||||
else:
|
||||
response = f"ERROR: {result['message']}\n"
|
||||
else:
|
||||
response = "ERROR: Empty command\n"
|
||||
except Exception as e:
|
||||
response = f"ERROR: {str(e)}\n"
|
||||
|
||||
# Send response back to client
|
||||
try:
|
||||
client_sock.send(response.encode("utf-8"))
|
||||
except:
|
||||
pass
|
||||
|
||||
try:
|
||||
data = rawdata.decode("utf-8").rstrip().lstrip()
|
||||
eventQueue.put({"Type":fenrirEventType.RemoteIncomming,
|
||||
"Data": data
|
||||
})
|
||||
except:
|
||||
pass
|
||||
try:
|
||||
client_sock.close()
|
||||
except:
|
||||
|
Loading…
x
Reference in New Issue
Block a user