diff options
author | Edward Thomson <ethomson@github.com> | 2016-02-22 23:46:50 -0500 |
---|---|---|
committer | Edward Thomson <ethomson@github.com> | 2016-02-28 12:38:39 -0500 |
commit | 22a19f5b5795153b4c77c75adfae790c3b919be4 (patch) | |
tree | 0aa5122a98f379b9ebd11e35b6e8ae48490fd0f8 /include/git2/common.h | |
parent | 6cc4bac894281d3e80e1861c1ccb0e234cbd9bb0 (diff) | |
download | libgit2-22a19f5b5795153b4c77c75adfae790c3b919be4.tar.gz |
git_libgit2_opts: introduce `GIT_OPT_ENABLE_STRICT_OBJECT_CREATION`
Diffstat (limited to 'include/git2/common.h')
-rw-r--r-- | include/git2/common.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/git2/common.h b/include/git2/common.h index c26030840..4f43185f8 100644 --- a/include/git2/common.h +++ b/include/git2/common.h @@ -147,6 +147,7 @@ typedef enum { GIT_OPT_SET_TEMPLATE_PATH, GIT_OPT_SET_SSL_CERT_LOCATIONS, GIT_OPT_SET_USER_AGENT, + GIT_OPT_ENABLE_STRICT_OBJECT_CREATION, } git_libgit2_opt_t; /** @@ -251,6 +252,14 @@ typedef enum { * > - `user_agent` is the value that will be delivered as the * > User-Agent header on HTTP requests. * + * * opts(GIT_OPT_ENABLE_STRICT_OBJECT_CREATION, int enabled) + * + * > Enable strict input validation when creating new objects + * > to ensure that all inputs to the new objects are valid. For + * > example, when this is enabled, the parent(s) and tree inputs + * > will be validated when creating a new commit. This defaults + * > to disabled. + * * @param option Option key * @param ... value to set the option * @return 0 on success, <0 on failure |