mirror of
https://github.com/tim-beatham/smegmesh.git
synced 2025-08-16 16:11:06 +02:00
Tidied up code, made changes for benchmarking.
This commit is contained in:
@ -31,8 +31,9 @@ func (n *IpcHandler) CreateMesh(args *ipc.NewMeshArgs, reply *string) error {
|
||||
WgPort: args.WgPort,
|
||||
Endpoint: args.Endpoint,
|
||||
})
|
||||
|
||||
*reply = meshId
|
||||
return nil
|
||||
return err
|
||||
}
|
||||
|
||||
func (n *IpcHandler) ListMeshes(_ string, reply *ipc.ListMeshReply) error {
|
||||
@ -51,6 +52,10 @@ func (n *IpcHandler) ListMeshes(_ string, reply *ipc.ListMeshReply) error {
|
||||
func (n *IpcHandler) JoinMesh(args ipc.JoinMeshArgs, reply *string) error {
|
||||
peerConnection, err := n.Server.ConnectionManager.GetConnection(args.IpAdress)
|
||||
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
client, err := peerConnection.GetClient()
|
||||
|
||||
if err != nil {
|
||||
|
Reference in New Issue
Block a user