mirror of
https://github.com/tmux/tmux.git
synced 2025-01-07 08:18:48 +00:00
Initialize default size variables, from Thomas Adam.
This commit is contained in:
parent
cf4566b47b
commit
4acd345c6a
@ -192,6 +192,8 @@ cmd_new_session_exec(struct cmd *self, struct cmdq_item *item)
|
|||||||
if (strcmp(tmp, "-") == 0) {
|
if (strcmp(tmp, "-") == 0) {
|
||||||
if (c != NULL)
|
if (c != NULL)
|
||||||
dsx = c->tty.sx;
|
dsx = c->tty.sx;
|
||||||
|
else
|
||||||
|
dsx = 80;
|
||||||
} else {
|
} else {
|
||||||
dsx = strtonum(tmp, 1, USHRT_MAX, &errstr);
|
dsx = strtonum(tmp, 1, USHRT_MAX, &errstr);
|
||||||
if (errstr != NULL) {
|
if (errstr != NULL) {
|
||||||
@ -205,6 +207,8 @@ cmd_new_session_exec(struct cmd *self, struct cmdq_item *item)
|
|||||||
if (strcmp(tmp, "-") == 0) {
|
if (strcmp(tmp, "-") == 0) {
|
||||||
if (c != NULL)
|
if (c != NULL)
|
||||||
dsy = c->tty.sy;
|
dsy = c->tty.sy;
|
||||||
|
else
|
||||||
|
dsy = 24;
|
||||||
} else {
|
} else {
|
||||||
dsy = strtonum(tmp, 1, USHRT_MAX, &errstr);
|
dsy = strtonum(tmp, 1, USHRT_MAX, &errstr);
|
||||||
if (errstr != NULL) {
|
if (errstr != NULL) {
|
||||||
|
Loading…
Reference in New Issue
Block a user