append_one_rev(): rewrite to work with object_id
[gitweb.git] / refs.h
diff --git a/refs.h b/refs.h
index 6d7d9b40f318119eea1e3240cca3a96d2c64e2a6..4042109f05d9d49384b04efb85dea43a53651e98 100644 (file)
--- a/refs.h
+++ b/refs.h
@@ -67,7 +67,18 @@ struct ref_transaction;
  * single callback invocation.
  */
 typedef int each_ref_fn(const char *refname,
-                       const unsigned char *sha1, int flags, void *cb_data);
+                       const struct object_id *oid, int flags, void *cb_data);
+
+typedef int each_ref_sha1_fn(const char *refname,
+                            const unsigned char *sha1, int flags, void *cb_data);
+
+struct each_ref_fn_sha1_adapter {
+       each_ref_sha1_fn *original_fn;
+       void *original_cb_data;
+};
+
+extern int each_ref_fn_adapter(const char *refname,
+                              const struct object_id *oid, int flags, void *cb_data);
 
 /*
  * The following functions invoke the specified callback function for