int i = 0;
if (list_empty(Incoming))
return (-1);
- i = CurBuffy;
+ i = CurBuffy + 1;
while (i < Incoming->length)
if (((BUFFY*) Incoming->data[i++])->msg_unread)
return (i-1);
int i = 0;
if (list_empty(Incoming))
return (-1);
- i = CurBuffy;
+ i = CurBuffy - 1;
while (i >= 0)
if (((BUFFY*) Incoming->data[i--])->msg_unread)
return (i+1);