summaryrefslogtreecommitdiff
path: root/builtin/describe.c
diff options
context:
space:
mode:
authorLibravatar Michael Haggerty <mhagger@alum.mit.edu>2012-11-25 12:08:39 +0100
committerLibravatar Junio C Hamano <gitster@pobox.com>2012-11-29 13:42:11 -0800
commitf035ab620520dbf286d3303194f10a489d7c7f56 (patch)
tree57da02b9d571a61f7c99906625655d591e2b895b /builtin/describe.c
parentimap-send: correctly report errors reading from stdin (diff)
downloadtgif-f035ab620520dbf286d3303194f10a489d7c7f56.tar.xz
imap-send: change msg_data from storing (ptr, len) to storing strbuf
struct msg_data stored (ptr, 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 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. By the way, 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 the future, a bunch of code could be ripped out and "struct msg_data" could be completely replaced with strbuf, but that would be a separate topic. Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/describe.c')
0 files changed, 0 insertions, 0 deletions