summaryrefslogtreecommitdiff
path: root/Documentation/technical
diff options
context:
space:
mode:
authorLibravatar Jeff King <peff@peff.net>2019-07-31 00:38:23 -0400
committerLibravatar Junio C Hamano <gitster@pobox.com>2019-08-01 13:06:52 -0700
commitc43ab062598d0299ea6e0d115a6018189a7793bf (patch)
tree03abcb873feb9ab6d23d51f9e7f45d1c2b14af26 /Documentation/technical
parenttree-walk: accept a raw length for traverse_path_len() (diff)
downloadtgif-c43ab062598d0299ea6e0d115a6018189a7793bf.tar.xz
tree-walk: add a strbuf wrapper for make_traverse_path()
All but one of the callers of make_traverse_path() allocate a new heap buffer to store the path. Let's give them an easy way to write to a strbuf, which saves them from computing the length themselves (which is especially tricky when they want to add to the path). It will also make it easier for us to change the make_traverse_path() interface in a future patch to improve its bounds-checking. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'Documentation/technical')
-rw-r--r--Documentation/technical/api-tree-walking.txt4
1 files changed, 4 insertions, 0 deletions
diff --git a/Documentation/technical/api-tree-walking.txt b/Documentation/technical/api-tree-walking.txt
index 59d78e0362..7962e32854 100644
--- a/Documentation/technical/api-tree-walking.txt
+++ b/Documentation/technical/api-tree-walking.txt
@@ -138,6 +138,10 @@ same in the next callback invocation.
This utilizes the memory structure of a tree entry to avoid the
overhead of using a generic strlen().
+`strbuf_make_traverse_path`::
+
+ Convenience wrapper to `make_traverse_path` into a strbuf.
+
Authors
-------