Re: [PATCH 6/8] imap-send: change msg_data from storing (char *, len) to storing strbuf

2012-12-03 Thread Thiago Farina
On Sat, Dec 1, 2012 at 11:48 PM, Junio C Hamano gits...@pobox.com wrote: I suggest a separate patch series dedicated to deleting *all* the extra imap infrastructure at once. That being said, I'm not committing to do so. (We could add it to an straightforward projects for aspiring git

Re: [PATCH 6/8] imap-send: change msg_data from storing (char *, len) to storing strbuf

2012-12-01 Thread Junio C Hamano
Michael Haggerty mhag...@alum.mit.edu writes: On 11/29/2012 10:30 PM, Junio C Hamano wrote: A side effect of this change is that the memory for each message is freed after it is used rather than leaked, though that detail is unimportant given that imap-send is a top-level command. -- ?

Re: [PATCH 6/8] imap-send: change msg_data from storing (char *, len) to storing strbuf

2012-12-01 Thread Michael Haggerty
On 12/02/2012 02:48 AM, Junio C Hamano wrote: Michael Haggerty mhag...@alum.mit.edu writes: On 11/29/2012 10:30 PM, Junio C Hamano wrote: A side effect of this change is that the memory for each message is freed after it is used rather than leaked, though that detail is unimportant given

Re: [PATCH 6/8] imap-send: change msg_data from storing (char *, len) to storing strbuf

2012-11-30 Thread Michael Haggerty
On 11/29/2012 10:30 PM, Junio C Hamano wrote: Michael Haggerty mhag...@alum.mit.edu writes: struct msg_data stored (char *, len) of the data to be included in a That (type, varname) is a bit funny notation, even though it is understandable. I understand that it is funny, but it seems like

Re: [PATCH 6/8] imap-send: change msg_data from storing (char *, len) to storing strbuf

2012-11-29 Thread Junio C Hamano
Michael Haggerty mhag...@alum.mit.edu writes: struct msg_data stored (char *, len) of the data to be included in a That (type, varname) is a bit funny notation, even though it is understandable. message, kept the character data NUL-terminated, etc., much like a strbuf would do. So change it

Re: [PATCH 6/8] imap-send: change msg_data from storing (char *, len) to storing strbuf

2012-11-29 Thread Jeff King
On Thu, Nov 29, 2012 at 01:30:54PM -0800, Junio C Hamano wrote: For some reason, there is a bunch of infrastructure in this file for dealing with IMAP flags, although there is nothing in the code that actually allows any flags to be set. If there is no plan to add support for flags in

[PATCH 6/8] imap-send: change msg_data from storing (char *, len) to storing strbuf

2012-11-25 Thread Michael Haggerty
struct msg_data stored (char *, len) of the data to be included in a message, kept the character data NUL-terminated, etc., much like a strbuf would do. So change it to use a struct strbuf. This makes the code clearer and reduces copying a little bit. A side effect of this change is that the