[Citadel Development] Re: Merge Request Approval: IMAP memory issues with use of ConstStr
Probably a role thing.
[Citadel Development] Re: Merge Request Approval: IMAP memory issues with use of ConstStr
Crap. Ok, I'll do the merge, but I really need to figure out what the heck is happening.
[Citadel Development] Re: Merge Request Approval: IMAP memory issues with use of ConstStr
I do not have permissions to check in. No button to merge and my icon shows "Cannot merge". I am logged in. > Mon Jul 31 2023 06:25:58 PM EDT from IGnatius T Foobar Subject: Re: Merge >Request Approval: IMAP memory issues with use of ConstStr > >Sorry about that, it just got away from me. I approved it. Looks good. > > > >
[Citadel Development] Re: Merge Request Approval: IMAP memory issues with use of ConstStr
Sorry about that, it just got away from me. I approved it. Looks good.
[Citadel Development] Re: Merge Request Approval: IMAP memory issues with use of ConstStr
This is still waiting for approval. Do you want me to bring the branch up to the head or anything else?
[Citadel Development] Re: Merge Request Approval: IMAP memory issues with use of ConstStr
I agree. The developer who introduced StrBuf and ConstBuf was helpful in giving us an elastic string class, but I wish he hadn't gone back through old code and converted stuff without a really deep inspection of how it was used.
[Citadel Development] Re: Merge Request Approval: IMAP memory issues with use of ConstStr
While looking at the use of ConstStr, it was interesting how it was being used. "Const" is definably not the description to use. It really is just a StrBuf where the pointer does not need to be freed. All sorts of code change the pointer string and really did not check what it is doing. Probably worth replacing the use in our copious spare time lol.
[Citadel Development] Re: Merge Request Approval: IMAP memory issues with use of ConstStr
>Not sure why the parameter was empty, but a lot of code accessed ConstStr >pointers without checking for zero length and pointer was null and could >coredump, so went through and added checks. *sigh* The IMAP server was written completely with straight C pointers and string buffers and it was extensively tested as it was built. Unfortunately, the developer who added StrBuf and ConstStr to libcitadel was a little too eager and converted a lot of code all throughout the system, and introduced subtle bugs everywhere.