Moved chat resource to WIN_CHAT type

This commit is contained in:
James Booth
2014-12-10 01:44:32 +00:00
parent 12d0d22ab3
commit 706f31422d
6 changed files with 19 additions and 17 deletions

View File

@@ -122,10 +122,9 @@ win_create(const char * const title, win_type_t type)
if (new_win->type == WIN_CHAT) {
new_win->wins.chat.is_otr = FALSE;
new_win->wins.chat.is_trusted = FALSE;
new_win->wins.chat.chat_resource = NULL;
}
new_win->chat_resource = NULL;
scrollok(new_win->win, TRUE);
return new_win;
@@ -223,7 +222,10 @@ win_free(ProfWin* window)
break;
}
free(window->chat_resource);
if (window->type == WIN_CHAT) {
free(window->wins.chat.chat_resource);
}
free(window->from);
if (window->type == WIN_MUC_CONFIG) {