Mail: correctly track the number of messages (thanks igor)
We forgot to update the message count when deleting messages in mail, meaning we could access trailing messages that had been freed.
This commit is contained in:
parent
dc8da7c232
commit
fd4e8eef0b
1 changed files with 1 additions and 0 deletions
|
@ -715,6 +715,7 @@ mbflush(char **, int)
|
|||
else
|
||||
mbox.mesg[j++] = m;
|
||||
}
|
||||
mbox.nmesg = j;
|
||||
|
||||
close(fd);
|
||||
fprint(mbox.ctl, "clean\n");
|
||||
|
|
Loading…
Reference in a new issue