summaryrefslogtreecommitdiff
path: root/refs.h
diff options
context:
space:
mode:
authorMichael Haggerty <mhagger@alum.mit.edu>2014-04-07 13:47:56 (GMT)
committerJunio C Hamano <gitster@pobox.com>2014-04-07 19:09:11 (GMT)
commitf412411245d4329307dec8ac0b1860c791cdb212 (patch)
tree2f5b7a142c26a2f95d9f2c075873e1fd6bc71d7e /refs.h
parent20fcffcc8de9fcfba15fce916ff38c98ca20323d (diff)
downloadgit-f412411245d4329307dec8ac0b1860c791cdb212.zip
git-f412411245d4329307dec8ac0b1860c791cdb212.tar.gz
git-f412411245d4329307dec8ac0b1860c791cdb212.tar.bz2
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 87a1a79..a713b34 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);