Remove pointless NULL check in repaint_window()

The function has already dereferenced the pointer and passing NULL to this function is just a bug.
This commit is contained in:
Kevin Easton
2017-07-15 22:24:09 +10:00
parent ce780c5b63
commit b481ed1e6e

View File

@@ -1397,9 +1397,8 @@ int BX_is_cursor_in_display(Screen *screen)
* If end_line is -1, then that means clear the display if any of it appears
* after the end of the scrollback buffer.
*/
void BX_repaint_window (Window *w, int start_line, int end_line)
void BX_repaint_window (Window *window, int start_line, int end_line)
{
Window *window = (Window *)w;
Display *curr_line;
int count;
int clean_display = 0;
@@ -1407,9 +1406,6 @@ void BX_repaint_window (Window *w, int start_line, int end_line)
if (dumb_mode || !window->visible)
return;
if (!window)
window = current_window;
if (end_line == -1)
{
end_line = window->display_size;