symbolic ref target validation: fixups

Fixups requested in #3912.
This commit is contained in:
Edward Thomson
2017-01-21 23:45:23 +00:00
parent 452bf57cbe
commit 28d0ba0ba5
4 changed files with 19 additions and 41 deletions

View File

@@ -157,7 +157,7 @@ typedef enum {
GIT_OPT_SET_SSL_CERT_LOCATIONS,
GIT_OPT_SET_USER_AGENT,
GIT_OPT_ENABLE_STRICT_OBJECT_CREATION,
GIT_OPT_ENABLE_SYMBOLIC_REF_TARGET_VALIDATION,
GIT_OPT_ENABLE_STRICT_SYMBOLIC_REF_CREATION,
GIT_OPT_SET_SSL_CIPHERS,
GIT_OPT_GET_USER_AGENT,
} git_libgit2_opt_t;
@@ -272,16 +272,14 @@ typedef enum {
* > will be validated when creating a new commit. This defaults
* > to disabled.
*
* * opts(GIT_OPT_ENABLE_SYMBOLIC_REF_TARGET_VALIDATION, int enabled)
* * opts(GIT_OPT_ENABLE_STRICT_SYMBOLIC_REF_CREATION, int enabled)
*
* > Validate the target of a symbolic ref when creating it.
* > For example, 'foobar' is not a valid ref,
* > therefore 'foobar' is not a valid target
* > for a symbolic ref by default,
* > where as 'refs/heads/foobar' is.
* > Disabling this bypasses validation so that an arbitrary
* > strings such as 'foobar' can be used for a symbolic ref target.
* > This defaults to enabled.
* > Validate the target of a symbolic ref when creating it. For
* > example, `foobar` is not a valid ref, therefore `foobar` is
* > not a valid target for a symbolic ref by default, whereas
* > `refs/heads/foobar` is. Disabling this bypasses validation
* > so that an arbitrary strings such as `foobar` can be used
* > for a symbolic ref target. This defaults to enabled.
*
* * opts(GIT_OPT_SET_SSL_CIPHERS, const char *ciphers)
*