Allow listing devices from remote.

This commit is contained in:
2019-10-12 23:12:39 +01:00
parent 58b2b84f0a
commit 580b8e0981
3 changed files with 60 additions and 27 deletions

View File

@@ -10,7 +10,7 @@ using Version = DiscImageChef.CommonTypes.Interop.Version;
namespace DiscImageChef.Devices.Remote
{
public class Remote
public class Remote : IDisposable
{
private readonly Socket _socket;
@@ -115,10 +115,20 @@ namespace DiscImageChef.Devices.Remote
public string ServerArchitecture { get; }
public int ServerProtocolVersion { get; }
public void Dispose()
{
Disconnect();
}
public void Disconnect()
{
_socket.Shutdown(SocketShutdown.Both);
_socket.Close();
}
public DeviceInfo[] ListDevices()
{
return new DeviceInfo[0];
}
}
}