diff options
author | Johannes Schindelin <johannes.schindelin@gmx.de> | 2021-03-17 18:30:49 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-03-17 22:19:28 +0300 |
commit | 4abc57848d8ace8218952c7376fa397c0850392c (patch) | |
tree | 4ac7659fc3cd30c6f16de71ca486fbc71e8f4f43 | |
parent | 3dfd30598bdb34078329aa9bd9b03c5ab5cdbcce (diff) |
fsmonitor: do not forget to release the token in `discard_index()`
In 56c6910028a (fsmonitor: change last update timestamp on the
index_state to opaque token, 2020-01-07), we forgot to adjust
`discard_index()` to release the "last-update" token: it is no longer a
64-bit number, but a free-form string that has been allocated.
Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r-- | read-cache.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/read-cache.c b/read-cache.c index 29144cf879..d19f506cd4 100644 --- a/read-cache.c +++ b/read-cache.c @@ -2355,6 +2355,7 @@ int discard_index(struct index_state *istate) cache_tree_free(&(istate->cache_tree)); istate->initialized = 0; istate->fsmonitor_has_run_once = 0; + FREE_AND_NULL(istate->fsmonitor_last_update); FREE_AND_NULL(istate->cache); istate->cache_alloc = 0; discard_split_index(istate); |