Load key before repo state - dedup - deduplicating backup program HTML git clone git://bitreich.org/dedup/ git://enlrupgkhuxnvlhsf6lc3fziv5h2hhfrinws65d7roiv6bfj7d652fid.onion/dedup/ DIR Log DIR Files DIR Refs DIR Tags DIR README DIR LICENSE --- DIR commit fcc899cbc1d3c835f1b28b9702e6965505ac8d66 DIR parent 95c553d5f0552ea0b2d2ec7937bf31336629c0d3 HTML Author: sin <sin@2f30.org> Date: Thu, 16 May 2019 14:09:05 +0300 Load key before repo state It might be needed in the repo state handling. Diffstat: M dup-check.c | 2 +- M dup-gc.c | 2 +- M dup-pack.c | 2 +- M dup-rm.c | 2 +- M dup-unpack.c | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) --- DIR diff --git a/dup-check.c b/dup-check.c @@ -127,8 +127,8 @@ main(int argc, char *argv[]) if ((lfd = lockrepo(repo)) < 0) errx(1, "failed to lock repository"); - loadstate(repo); loadkey(keyfile); + loadstate(repo); if (sopen(spath, S_READ, 0600, &sctx) < 0) printerr("sopen: %s", spath); DIR diff --git a/dup-gc.c b/dup-gc.c @@ -101,8 +101,8 @@ main(int argc, char *argv[]) if ((lfd = lockrepo(repo)) < 0) errx(1, "failed to lock repository"); - loadstate(repo); loadkey(keyfile); + loadstate(repo); if (bopen(path, B_RDWR, 0600, &bctx) < 0) printerr("bopen: %s", path); DIR diff --git a/dup-pack.c b/dup-pack.c @@ -128,8 +128,8 @@ main(int argc, char *argv[]) if ((lfd = lockrepo(repo)) < 0) errx(1, "failed to lock repository"); - loadstate(repo); loadkey(keyfile); + loadstate(repo); if (screat(spath, 0600, &sctx) < 0) printerr("screat: %s", spath); DIR diff --git a/dup-rm.c b/dup-rm.c @@ -116,8 +116,8 @@ main(int argc, char *argv[]) if ((lfd = lockrepo(repo)) < 0) errx(1, "failed to lock repository"); - loadstate(repo); loadkey(keyfile); + loadstate(repo); if (sopen(spath, S_READ, 0600, &sctx) < 0) printerr("sopen: %s", spath); DIR diff --git a/dup-unpack.c b/dup-unpack.c @@ -125,8 +125,8 @@ main(int argc, char *argv[]) if ((lfd = lockrepo(repo)) < 0) errx(1, "failed to lock repository"); - loadstate(repo); loadkey(keyfile); + loadstate(repo); if (sopen(spath, S_READ, 0600, &sctx) < 0) printerr("sopen: %s", spath);