]> git.armaanb.net Git - stagit.git/blobdiff - stagit.c
fix compile: libgit2 0.28 changed giterr_last to git_error_last
[stagit.git] / stagit.c
index 093cdabb1c8ea7aac953e590522e61b7602192d8..c2b2f2cb7c48c7ec0932f35b587cd1faea14a30d 100644 (file)
--- a/stagit.c
+++ b/stagit.c
@@ -1054,7 +1054,6 @@ main(int argc, char *argv[])
 {
        git_object *obj = NULL;
        const git_oid *head = NULL;
-       const git_error *e = NULL;
        mode_t mask;
        FILE *fp, *fpread;
        char path[PATH_MAX], repodirabs[PATH_MAX + 1], *p;
@@ -1101,8 +1100,7 @@ main(int argc, char *argv[])
 
        if (git_repository_open_ext(&repo, repodir,
                GIT_REPOSITORY_OPEN_NO_SEARCH, NULL) < 0) {
-               e = giterr_last();
-               fprintf(stderr, "%s: %s\n", argv[0], e->message);
+               fprintf(stderr, "%s: cannot open repository\n", argv[0]);
                return 1;
        }