Skip to contentSkip to conversation

refs-internal.c: make files_log_ref_write() static

PATCH In review Nguyễn Thái Ngọc Duy 2 participants 2 messages Feb 8, 2017

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 refs-internal.c: make files_log_ref_write() static

Created in 5f3c3a4e6f (files_log_ref_write: new function - 2015-11-10) but probably never used outside refs-internal.c

---
 refs/files-backend.c | 3 +++
 refs/refs-internal.h | 4 ----
 2 files changed, 3 insertions(+), 4 deletions(-)
refs/files-backend.c +3 -0
index c041d4ba21..6a0bf94bf1 100644
@@ -165,6 +165,9 @@ static struct ref_entry *create_dir_entry(struct files_ref_store *ref_store,
 					  const char *dirname, size_t len,
 					  int incomplete);
 static void add_entry_to_dir(struct ref_dir *dir, struct ref_entry *entry);
+static int files_log_ref_write(const char *refname, const unsigned char *old_sha1,
+			       const unsigned char *new_sha1, const char *msg,
+			       int flags, struct strbuf *err);
 
 static struct ref_dir *get_ref_dir(struct ref_entry *entry)
 {
refs/refs-internal.h +0 -4
index 25444cf5b0..4c9215d33f 100644
@@ -220,10 +220,6 @@ struct ref_transaction {
 	enum ref_transaction_state state;
 };
 
-int files_log_ref_write(const char *refname, const unsigned char *old_sha1,
-			const unsigned char *new_sha1, const char *msg,
-			int flags, struct strbuf *err);
-
 /*
  * Check for entries in extras that are within the specified
  * directory, where dirname is a reference directory name including
Signature · 1 line
2.11.0.157.gd943d85
#1 lore raw
Quoted 5 lines · Nguyễn Thái Ngọc Duy

Created in 5f3c3a4e6f (files_log_ref_write: new function - 2015-11-10) but probably never used outside refs-internal.c

---

It's been more than a year, so let's declare that when somebody needs it it can easily be turned into extern again and take this patch.

Thanks.

Quoted 33 lines
 refs/files-backend.c | 3 +++
 refs/refs-internal.h | 4 ----
 2 files changed, 3 insertions(+), 4 deletions(-)
refs/files-backend.c +3 -0
index c041d4ba21..6a0bf94bf1 100644
@@ -165,6 +165,9 @@ static struct ref_entry *create_dir_entry(struct files_ref_store *ref_store,
 					  const char *dirname, size_t len,
 					  int incomplete);
 static void add_entry_to_dir(struct ref_dir *dir, struct ref_entry *entry);
+static int files_log_ref_write(const char *refname, const unsigned char *old_sha1,
+			       const unsigned char *new_sha1, const char *msg,
+			       int flags, struct strbuf *err);
 
 static struct ref_dir *get_ref_dir(struct ref_entry *entry)
 {
refs/refs-internal.h +0 -4
index 25444cf5b0..4c9215d33f 100644
@@ -220,10 +220,6 @@ struct ref_transaction {
 	enum ref_transaction_state state;
 };
 
-int files_log_ref_write(const char *refname, const unsigned char *old_sha1,
-			const unsigned char *new_sha1, const char *msg,
-			int flags, struct strbuf *err);
-
 /*
  * Check for entries in extras that are within the specified
  * directory, where dirname is a reference directory name including