Skip to content
Snippets Groups Projects
Commit f63fa9d7 authored by George Nachman's avatar George Nachman
Browse files

Don't try to resize terminated sessions and don't allow sessions smaller than...

Don't try to resize terminated sessions and don't allow sessions smaller than 1x1. Fixes crash when closing a window in IR while another window exists and is key.
parent 6fd9f057
No related branches found
No related tags found
No related merge requests found
Loading
Loading
@@ -3503,6 +3503,9 @@ NSString *sessionsKey = @"sessions";
// Set the session to a size that fits on the screen.
- (void)safelySetSessionSize:(PTYSession*)aSession rows:(int)rows columns:(int)columns
{
if ([aSession exited]) {
return;
}
PtyLog(@"safelySetSessionSize");
BOOL hasScrollbar = !_fullScreen && ![[PreferencePanel sharedInstance] hideScrollbar];
if (windowType_ == WINDOW_TYPE_NORMAL) {
Loading
Loading
Loading
Loading
@@ -838,6 +838,8 @@ static char* FormatCont(int c)
if (WIDTH == 0 || HEIGHT == 0 || (new_width==WIDTH && new_height==HEIGHT)) {
return;
}
new_width = MAX(new_width, 1);
new_height = MAX(new_height, 1);
 
// create a new buffer and fill it with the default line.
new_buffer_lines = (screen_char_t*)calloc(new_height * (new_width+1),
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment