mailbox: move the header and mbentry data into sub-parts of struct mailbox
This is a pretty large commit because it has to update flagname to h.flagname in
a lot of places, plus update inside mailbox.c a lot.
It also contains some bugfixes which are unfortunately hard to separate out,
so I gave up on splitting them. These are:
- the listitems in mailbox.c now have a copy of the name too, rather than embedding deep into the struct mailbox.
- we always read the ACL when we read the header.
- we keep separate copies of the header data and mbentry data
- gaps in flagnames can exist if we remove_flag - we can now insert a NIL and still read/write correctly
- the 'N' name now writes into the cyrus.header copy (we're still not storing the H() name history, that's for another commit.
- we're copying the mbentry passed in, so there's some tidying mboxlist.c as well around what gets passed in the mbentry.