Thread (1 message) 1 message, 1 author, 2016-06-15

Re: [PATCH 1/2] pack-refs: remove all empty directories under $GIT_DIR/refs

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:53:03

Nguyen Thai Ngoc Duy [off-list ref] writes:
2012/2/11 Junio C Hamano [off-list ref]:
quoted
Nguyễn Thái Ngọc Duy [off-list ref] writes:
...
quoted
Would it make more sense to note the
directory for which rmdir() fails in try_remove_empty_parents(), and
revisit only these directories, at least?
That would leave empty directories not sharing the ref's path until
the failed rmdir() unexamined, I think.
True. Thanks.
quoted
quoted
+     subpath = xmalloc(pathlen + 257);
What is this 257 about?
This function is a ripoff from get_ref_dir(). I think 257 is 255 below
plus '/' and NIL.
I do not think there is any justification to copy-and-paste from code that
predates the strbuf infrastructure these days.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help