Fix a curses bug exposed by the ":numbers" display of systat -iostat.
This bug showed up when you had more than 3 devices displayed. (thus requiring a second line of display) Here's a quote From the PR: When wrefresh() is called with a subwindow as argument, __set_subwin might be called with reversed arguments if wrefresh() decides to calls quickch(). This may cause use of negative array indexes, with a resulting segfault. Since quickch() manipulates the line structures belonging to curscr, it looks like all subwindows of curscr should be updated. PR: bin/8086 Submitted by: Tor Egge <Tor.Egge@fast.no>
This commit is contained in:
parent
d6be4d69fc
commit
02334afb12
@ -682,8 +682,8 @@ quickch(win)
|
|||||||
* Need to repoint any subwindow lines to the rotated
|
* Need to repoint any subwindow lines to the rotated
|
||||||
* line structured.
|
* line structured.
|
||||||
*/
|
*/
|
||||||
for (wp = win->nextp; wp != win; wp = wp->nextp)
|
for (wp = curscr->nextp; wp != curscr; wp = wp->nextp)
|
||||||
__set_subwin(win, wp);
|
__set_subwin(wp->orig, wp);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user