summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Rogers <alan@github.com>2014-05-30 16:21:49 -0700
committerAlan Rogers <alan@github.com>2014-05-30 16:21:49 -0700
commit66271925a118040eac4d18230cfa88461c1e3788 (patch)
tree636f38155b5db4c34446989b99935bbe4af4dbe7
parenta777fc378583ca88f860c1d770bb959c25bec276 (diff)
downloadlibgit2-66271925a118040eac4d18230cfa88461c1e3788.tar.gz
Add GIT_STATUS_OPT_INCLUDE_UNREADABLE
-rw-r--r--include/git2/status.h1
-rw-r--r--src/status.c2
2 files changed, 3 insertions, 0 deletions
diff --git a/include/git2/status.h b/include/git2/status.h
index 794a629af..858f68841 100644
--- a/include/git2/status.h
+++ b/include/git2/status.h
@@ -148,6 +148,7 @@ typedef enum {
GIT_STATUS_OPT_RENAMES_FROM_REWRITES = (1u << 11),
GIT_STATUS_OPT_NO_REFRESH = (1u << 12),
GIT_STATUS_OPT_UPDATE_INDEX = (1u << 13),
+ GIT_STATUS_OPT_INCLUDE_UNREADABLE = (1u << 14),
} git_status_opt_t;
#define GIT_STATUS_OPT_DEFAULTS \
diff --git a/src/status.c b/src/status.c
index 6b8009854..5a592a7c5 100644
--- a/src/status.c
+++ b/src/status.c
@@ -313,6 +313,8 @@ int git_status_list_new(
diffopt.flags = diffopt.flags | GIT_DIFF_IGNORE_SUBMODULES;
if ((flags & GIT_STATUS_OPT_UPDATE_INDEX) != 0)
diffopt.flags = diffopt.flags | GIT_DIFF_UPDATE_INDEX;
+ if ((flags & GIT_STATUS_OPT_INCLUDE_UNREADABLE) != 0)
+ diffopt.flags = diffopt.flags | GIT_DIFF_INCLUDE_UNREADABLE;
if ((flags & GIT_STATUS_OPT_RENAMES_FROM_REWRITES) != 0)
findopt.flags = findopt.flags |