Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
refs.c: Remove unused get_ref_sha1()
author
Johannes Sixt
<johannes.sixt@telecom.at>
Thu, 15 Nov 2007 16:33:44 +0000
(17:33 +0100)
committer
Junio C Hamano
<gitster@pobox.com>
Fri, 16 Nov 2007 05:16:51 +0000
(21:16 -0800)
Signed-off-by: Johannes Sixt <johannes.sixt@telecom.at>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
refs.c
patch
|
blob
|
history
refs.h
patch
|
blob
|
history
raw
|
patch
|
inline
| side by side (parent:
039bc64
)
diff --git
a/refs.c
b/refs.c
index aff02cd09d4e40b04f6764a6f6ab43240b736a08..ae532540cf2592aee2be7610ac811082c3a9b6be 100644
(file)
--- a/
refs.c
+++ b/
refs.c
@@
-580,18
+580,6
@@
int for_each_remote_ref(each_ref_fn fn, void *cb_data)
return do_for_each_ref("refs/remotes/", fn, 13, cb_data);
}
return do_for_each_ref("refs/remotes/", fn, 13, cb_data);
}
-/* NEEDSWORK: This is only used by ssh-upload and it should go; the
- * caller should do resolve_ref or read_ref like everybody else. Or
- * maybe everybody else should use get_ref_sha1() instead of doing
- * read_ref().
- */
-int get_ref_sha1(const char *ref, unsigned char *sha1)
-{
- if (check_ref_format(ref))
- return -1;
- return read_ref(mkpath("refs/%s", ref), sha1);
-}
-
/*
* Make sure "ref" is something reasonable to have under ".git/refs/";
* We do not like it if:
/*
* Make sure "ref" is something reasonable to have under ".git/refs/";
* We do not like it if:
diff --git
a/refs.h
b/refs.h
index 6eb98a4caf150776c26fb04699133b1a976d0122..9dc8aa01d181dbdbf1c8f643a1bd7de1d311ffa3 100644
(file)
--- a/
refs.h
+++ b/
refs.h
@@
-26,9
+26,6
@@
extern int for_each_remote_ref(each_ref_fn, void *);
extern int peel_ref(const char *, unsigned char *);
extern int peel_ref(const char *, unsigned char *);
-/** Reads the refs file specified into sha1 **/
-extern int get_ref_sha1(const char *ref, unsigned char *sha1);
-
/** Locks a "refs/" ref returning the lock on success and NULL on failure. **/
extern struct ref_lock *lock_ref_sha1(const char *ref, const unsigned char *old_sha1);
/** Locks a "refs/" ref returning the lock on success and NULL on failure. **/
extern struct ref_lock *lock_ref_sha1(const char *ref, const unsigned char *old_sha1);