mirror of
https://github.com/git/git.git
synced 2026-01-09 17:46:37 +00:00
Create object subdirectories on demand (phase II)
This removes the unoptimization. The previous round does not mind missing fan-out directories, but still makes sure they exist, lest older versions choke on a repository created/packed by it. This round does not play that nicely anymore -- empty fan-out directories are not created by init-db, and will stay removed by prune-packed. The prune command also removes empty fan-out directories. Signed-off-by: Junio C Hamano <junkio@cox.net>
This commit is contained in:
committed by
Junio C Hamano
parent
c1aaa5d9ea
commit
9106c097ad
@@ -27,8 +27,7 @@ static void prune_dir(int i, DIR *dir, char *pathname, int len)
|
||||
error("unable to unlink %s", pathname);
|
||||
}
|
||||
pathname[len] = 0;
|
||||
if (!rmdir(pathname))
|
||||
mkdir(pathname, 0777);
|
||||
rmdir(pathname);
|
||||
}
|
||||
|
||||
static void prune_packed_objects(void)
|
||||
|
||||
Reference in New Issue
Block a user