mirror of
https://github.com/tmate-io/tmate.git
synced 2025-08-16 00:28:10 +02:00
Major reorganisation of screen handling.
This commit is contained in:
@ -1,4 +1,4 @@
|
||||
/* $Id: cmd-switch-client.c,v 1.1 2007-11-16 21:31:03 nicm Exp $ */
|
||||
/* $Id: cmd-switch-client.c,v 1.2 2007-12-06 09:46:22 nicm Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2007 Nicholas Marriott <nicm@users.sourceforge.net>
|
||||
@ -42,7 +42,7 @@ const struct cmd_entry cmd_switch_client_entry = {
|
||||
"switch-client", "switchc", "session-name",
|
||||
CMD_NOSESSION,
|
||||
cmd_switch_client_parse,
|
||||
cmd_switch_client_exec,
|
||||
cmd_switch_client_exec,
|
||||
cmd_switch_client_send,
|
||||
cmd_switch_client_recv,
|
||||
cmd_switch_client_free
|
||||
@ -62,7 +62,7 @@ cmd_switch_client_parse(void **ptr, int argc, char **argv, char **cause)
|
||||
default:
|
||||
goto usage;
|
||||
}
|
||||
}
|
||||
}
|
||||
argc -= optind;
|
||||
argv += optind;
|
||||
if (argc != 1)
|
||||
@ -88,14 +88,14 @@ cmd_switch_client_exec(void *ptr, struct cmd_ctx *ctx)
|
||||
|
||||
if (data == NULL)
|
||||
return;
|
||||
|
||||
|
||||
if ((s = session_find(data->name)) == NULL) {
|
||||
ctx->error(ctx, "session not found: %s", data->name);
|
||||
return;
|
||||
}
|
||||
|
||||
ctx->client->session = s;
|
||||
|
||||
|
||||
recalculate_sizes();
|
||||
server_redraw_client(ctx->client);
|
||||
|
||||
|
Reference in New Issue
Block a user