From 78944c815a5d8d1c93771ca1c343b9406bc262c4 Mon Sep 17 00:00:00 2001 From: Tavian Barnes Date: Sun, 26 Sep 2021 15:23:26 -0400 Subject: Don't truncate files until we know they're not duplicates --- ctx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'ctx.c') diff --git a/ctx.c b/ctx.c index 450d87e..c86e41d 100644 --- a/ctx.c +++ b/ctx.c @@ -161,7 +161,7 @@ struct bfs_ctx_file { const char *path; }; -struct CFILE *bfs_ctx_dedup(struct bfs_ctx *ctx, CFILE *cfile, const char *path) { +CFILE *bfs_ctx_dedup(struct bfs_ctx *ctx, CFILE *cfile, const char *path) { struct bfs_stat sb; if (bfs_stat(fileno(cfile->file), NULL, 0, &sb) != 0) { return NULL; -- cgit v1.2.3