git/Documentation/technical
Jeff King c460c0ecdc run-command: store an optional argv_array
All child_process structs need to point to an argv. For
flexibility, we do not mandate the use of a dynamic
argv_array. However, because the child_process does not own
the memory, this can make memory management with a
separate argv_array difficult.

For example, if a function calls start_command but not
finish_command, the argv memory must persist. The code needs
to arrange to clean up the argv_array separately after
finish_command runs. As a result, some of our code in this
situation just leaks the memory.

To help such cases, this patch adds a built-in argv_array to
the child_process, which gets cleaned up automatically (both
in finish_command and when start_command fails).  Callers
may use it if they choose, but can continue to use the raw
argv if they wish.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
2014-05-15 09:49:09 -07:00
..
.gitignore
api-allocation-growing.txt
api-argv-array.txt
api-builtin.txt builtin/help.c: speed up is_git_command() by checking for builtin commands first 2014-01-06 11:26:31 -08:00
api-config.txt
api-credentials.txt
api-decorate.txt
api-diff.txt
api-directory-listing.txt
api-gitattributes.txt Documentation: fix misuses of "nor" 2014-03-31 15:16:22 -07:00
api-grep.txt
api-hashmap.txt hashmap.h: use 'unsigned int' for hash-codes everywhere 2014-02-24 15:26:30 -08:00
api-history-graph.txt
api-in-core-index.txt
api-index-skel.txt
api-index.sh
api-lockfile.txt
api-merge.txt
api-object-access.txt
api-parse-options.txt parse-options: remove unused OPT_SET_PTR 2014-03-31 13:01:19 -07:00
api-quote.txt
api-ref-iteration.txt
api-remote.txt
api-revision-walking.txt
api-run-command.txt run-command: store an optional argv_array 2014-05-15 09:49:09 -07:00
api-setup.txt
api-sha1-array.txt
api-sigchain.txt
api-strbuf.txt
api-string-list.txt
api-tree-walking.txt
api-xdiff-interface.txt
bitmap-format.txt
http-protocol.txt Documentation: fix documentation AsciiDoc links for external urls 2014-02-20 14:14:58 -08:00
index-format.txt
pack-format.txt
pack-heuristics.txt pack-heuristics.txt: mark up the file header properly 2014-01-13 11:18:34 -08:00
pack-protocol.txt Documentation: fix misuses of "nor" 2014-03-31 15:16:22 -07:00
protocol-capabilities.txt protocol-capabilities.txt: document no-done 2014-02-10 10:21:33 -08:00
protocol-common.txt Documentation: fix misuses of "nor" 2014-03-31 15:16:22 -07:00
racy-git.txt
send-pack-pipeline.txt
shallow.txt
trivial-merge.txt