Fix STATUS_NOTIFY so that it appears in the right window.

The old code was reusing the 'window' variable, which means that it
could pick up the STATUS_NOTIFY format from the wrong window.  You
would only have noticed this if you have windows with different settings
for STATUS_NOTIFY.


git-svn-id: svn://svn.code.sf.net/p/bitchx/code/trunk@425 13b04d17-f746-0410-82c6-800466cd88b0
This commit is contained in:
Kevin Easton
2013-10-29 13:25:10 +00:00
parent e9d180f526
commit 02327eebae
2 changed files with 6 additions and 4 deletions

View File

@@ -988,14 +988,14 @@ static char *status_notify_windows(Window *window)
if (get_int_var(SHOW_STATUS_ALL_VAR) || window == window->screen->current_window)
{
*notes = 0;
window = NULL;
while ((traverse_all_windows(&window)))
Window *notify_win = NULL;
while ((traverse_all_windows(&notify_win)))
{
if (window->miscflags & WINDOW_NOTIFIED)
if (notify_win->miscflags & WINDOW_NOTIFIED)
{
if (doneone++)
strlcat(notes, ",", sizeof notes);
strlcat(notes, ltoa(window->refnum), sizeof notes);
strlcat(notes, ltoa(notify_win->refnum), sizeof notes);
}
}
}