mirror of
https://github.com/Tha14/toxic.git
synced 2024-11-12 23:33:03 +01:00
forgot a lock
This commit is contained in:
parent
aeb70262e0
commit
9d52b6ab5d
@ -360,8 +360,12 @@ static void friendlist_onDraw(ToxWindow *self, Tox *m)
|
||||
wprintw(self->window, "key.\n\n");
|
||||
wattroff(self->window, COLOR_PAIR(CYAN));
|
||||
|
||||
pthread_mutex_lock(&Winthread.lock);
|
||||
int nf = tox_get_num_online_friends(m);
|
||||
pthread_mutex_unlock(&Winthread.lock);
|
||||
|
||||
wattron(self->window, A_BOLD);
|
||||
wprintw(self->window, " Online: %d/%d \n\n", tox_get_num_online_friends(m), num_friends);
|
||||
wprintw(self->window, " Online: %d/%d \n\n", nf, num_friends);
|
||||
wattroff(self->window, A_BOLD);
|
||||
|
||||
if ((y2 - FLIST_OFST) <= 0) /* don't allow division by zero */
|
||||
|
@ -405,7 +405,6 @@ void draw_active_window(Tox *m)
|
||||
a->onKey(a, m, ch);
|
||||
pthread_mutex_unlock(&Winthread.lock);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
int get_num_active_windows(void)
|
||||
|
Loading…
Reference in New Issue
Block a user