summaryrefslogtreecommitdiffstats
path: root/ctx.c
diff options
context:
space:
mode:
authorTavian Barnes <tavianator@tavianator.com>2021-09-26 15:23:26 -0400
committerTavian Barnes <tavianator@tavianator.com>2021-09-26 15:23:26 -0400
commit78944c815a5d8d1c93771ca1c343b9406bc262c4 (patch)
tree0e11144b526a3a1cebeedf4f7277b60d40488580 /ctx.c
parent2e918d33be152c1a57ffb3ff53e344cafb161a8c (diff)
downloadbfs-78944c815a5d8d1c93771ca1c343b9406bc262c4.tar.xz
Don't truncate files until we know they're not duplicates
Diffstat (limited to 'ctx.c')
-rw-r--r--ctx.c2
1 files changed, 1 insertions, 1 deletions
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;