From a6b3de3bfd4b219cd7ae92bedcc419eb5aa51dda Mon Sep 17 00:00:00 2001 From: Ben Peart Date: Mon, 5 Nov 2018 08:38:32 -0500 Subject: [PATCH] At the end of the add command, disable and free the fscache so that we don't leak the memory and so that we can dump the fscache statistics. Signed-off-by: Ben Peart --- builtin/add.c | 1 + 1 file changed, 1 insertion(+) diff --git a/builtin/add.c b/builtin/add.c index fa5175a37fa265..74d8e8b55706cf 100644 --- a/builtin/add.c +++ b/builtin/add.c @@ -615,6 +615,7 @@ int cmd_add(int argc, const char **argv, const char *prefix) COMMIT_LOCK | SKIP_IF_UNCHANGED)) die(_("Unable to write new index file")); + enable_fscache(0); UNLEAK(pathspec); UNLEAK(dir); return exit_status;