summaryrefslogtreecommitdiff
path: root/stagit-index.c
diff options
context:
space:
mode:
Diffstat (limited to 'stagit-index.c')
-rw-r--r--stagit-index.c7
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++) {