mirror of
https://github.com/tmux/tmux.git
synced 2024-12-04 19:58:48 +00:00
Fix some error strings, from Kris Katterjohn.
This commit is contained in:
parent
bbfb44e9b2
commit
dc893405e1
@ -407,11 +407,11 @@ args_string_percentage(const char *value, long long minval, long long maxval,
|
||||
}
|
||||
ll = (curval * ll) / 100;
|
||||
if (ll < minval) {
|
||||
*cause = xstrdup("too large");
|
||||
*cause = xstrdup("too small");
|
||||
return (0);
|
||||
}
|
||||
if (ll > maxval) {
|
||||
*cause = xstrdup("too small");
|
||||
*cause = xstrdup("too large");
|
||||
return (0);
|
||||
}
|
||||
} else {
|
||||
|
@ -117,7 +117,7 @@ cmd_resize_pane_exec(struct cmd *self, struct cmdq_item *item)
|
||||
if (args_has(args, 'y')) {
|
||||
y = args_percentage(args, 'y', 0, INT_MAX, w->sy, &cause);
|
||||
if (cause != NULL) {
|
||||
cmdq_error(item, "width %s", cause);
|
||||
cmdq_error(item, "height %s", cause);
|
||||
free(cause);
|
||||
return (CMD_RETURN_ERROR);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user