diff options
author | ailin-nemui <ailin-nemui@users.noreply.github.com> | 2018-02-02 10:05:37 +0100 |
---|---|---|
committer | ailin-nemui <ailin-nemui@users.noreply.github.com> | 2018-02-02 10:05:37 +0100 |
commit | 5b5bfef03596d95079c728f65f523570dd7b03aa (patch) | |
tree | 2f680d5ed978d83f9c9627288dd3b7e9536a9cd2 /src | |
parent | 6d42c4f949ab7d3d403d2f31d6a816961a180e2b (diff) | |
download | irssi-5b5bfef03596d95079c728f65f523570dd7b03aa.zip |
check the error condition of mainwindow_create
Diffstat (limited to 'src')
-rw-r--r-- | src/fe-text/mainwindows.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/src/fe-text/mainwindows.c b/src/fe-text/mainwindows.c index 5f24674f..0c77bcf1 100644 --- a/src/fe-text/mainwindows.c +++ b/src/fe-text/mainwindows.c @@ -1393,6 +1393,11 @@ static void _cmd_window_show_opt(const char *data, int right) } parent = mainwindow_create(right); + if (parent == NULL) { + printformat_window(active_win, MSGLEVEL_CLIENTERROR, TXT_WINDOW_TOO_SMALL); + return; + } + parent->active = window; gui_window_reparent(window, parent); |