diff options
author | Hiltjo Posthuma <hiltjo@codemadness.org> | 2018-04-06 19:28:05 +0200 |
---|---|---|
committer | Hiltjo Posthuma <hiltjo@codemadness.org> | 2018-04-06 19:28:05 +0200 |
commit | 6a1224afae24c2ae875978108137962e64dc2d24 (patch) | |
tree | 869c73effed5bc2234da38e9cf30ce57b9adef41 | |
parent | 3c07e52f98b0f49250c3de026b31202b426eb45a (diff) | |
download | stagit-fork-6a1224afae24c2ae875978108137962e64dc2d24.zip |
stagit-index: pledge after git_libgit2_init
-rw-r--r-- | stagit-index.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/stagit-index.c b/stagit-index.c index 09e5513..6b7c699 100644 --- a/stagit-index.c +++ b/stagit-index.c @@ -157,15 +157,16 @@ main(int argc, char *argv[]) const char *repodir; int i, ret = 0; - if (pledge("stdio rpath", NULL) == -1) - err(1, "pledge"); - if (argc < 2) { fprintf(stderr, "%s [repodir...]\n", argv[0]); return 1; } + git_libgit2_init(); + if (pledge("stdio rpath", NULL) == -1) + err(1, "pledge"); + writeheader(stdout); for (i = 1; i < argc; i++) { |