summaryrefslogtreecommitdiff
path: root/refs.h
diff options
context:
space:
mode:
authorLibravatar Michael Haggerty <mhagger@alum.mit.edu>2014-04-07 15:47:56 +0200
committerLibravatar Junio C Hamano <gitster@pobox.com>2014-04-07 12:09:11 -0700
commitf412411245d4329307dec8ac0b1860c791cdb212 (patch)
tree2f5b7a142c26a2f95d9f2c075873e1fd6bc71d7e /refs.h
parentt1400: add some more tests involving quoted arguments (diff)
downloadtgif-f412411245d4329307dec8ac0b1860c791cdb212.tar.xz
refs.h: rename the action_on_err constants
Given that these constants are only being used when updating references, it is inappropriate to give them such generic names as "DIE_ON_ERR". So prefix their names with "UPDATE_REFS_". Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'refs.h')
-rw-r--r--refs.h9
1 files changed, 7 insertions, 2 deletions
diff --git a/refs.h b/refs.h
index 87a1a79ad6..a713b34ad8 100644
--- a/refs.h
+++ b/refs.h
@@ -214,8 +214,13 @@ extern int rename_ref(const char *oldref, const char *newref, const char *logmsg
*/
extern int resolve_gitlink_ref(const char *path, const char *refname, unsigned char *sha1);
-/** lock a ref and then write its file */
-enum action_on_err { MSG_ON_ERR, DIE_ON_ERR, QUIET_ON_ERR };
+enum action_on_err {
+ UPDATE_REFS_MSG_ON_ERR,
+ UPDATE_REFS_DIE_ON_ERR,
+ UPDATE_REFS_QUIET_ON_ERR
+};
+
+/** Lock a ref and then write its file */
int update_ref(const char *action, const char *refname,
const unsigned char *sha1, const unsigned char *oldval,
int flags, enum action_on_err onerr);