version 1.6, 2011/09/28 20:11:21 |
version 1.7, 2012/07/11 07:10:15 |
|
|
* Refresh client. |
* Refresh client. |
*/ |
*/ |
|
|
int cmd_refresh_client_exec(struct cmd *, struct cmd_ctx *); |
enum cmd_retval cmd_refresh_client_exec(struct cmd *, struct cmd_ctx *); |
|
|
const struct cmd_entry cmd_refresh_client_entry = { |
const struct cmd_entry cmd_refresh_client_entry = { |
"refresh-client", "refresh", |
"refresh-client", "refresh", |
|
|
cmd_refresh_client_exec |
cmd_refresh_client_exec |
}; |
}; |
|
|
int |
enum cmd_retval |
cmd_refresh_client_exec(struct cmd *self, struct cmd_ctx *ctx) |
cmd_refresh_client_exec(struct cmd *self, struct cmd_ctx *ctx) |
{ |
{ |
struct args *args = self->args; |
struct args *args = self->args; |
struct client *c; |
struct client *c; |
|
|
if ((c = cmd_find_client(ctx, args_get(args, 't'))) == NULL) |
if ((c = cmd_find_client(ctx, args_get(args, 't'))) == NULL) |
return (-1); |
return (CMD_RETURN_ERROR); |
|
|
if (args_has(args, 'S')) { |
if (args_has(args, 'S')) { |
status_update_jobs(c); |
status_update_jobs(c); |
|
|
} else |
} else |
server_redraw_client(c); |
server_redraw_client(c); |
|
|
return (0); |
return (CMD_RETURN_NORMAL); |
} |
} |