fixup! Introduce helper to create symlinks that knows about index_state

We do not actually need to test for `state != NULL`, as
`state->delayed_checkout` had already been accessed before this.

Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de>
This commit is contained in:
Johannes Schindelin
2019-05-09 13:47:49 +02:00
parent ea7a305a45
commit 0ccd8caa6a

View File

@@ -289,7 +289,7 @@ static int write_entry(struct cache_entry *ce,
if (!has_symlinks || to_tempfile)
goto write_file_entry;
ret = create_symlink(state ? state->istate : NULL, new_blob, path);
ret = create_symlink(state->istate, new_blob, path);
free(new_blob);
if (ret)
return error_errno("unable to create symlink %s", path);