diff options
Diffstat (limited to 'refs/files-backend.c')
| -rw-r--r-- | refs/files-backend.c | 15 | 
1 files changed, 9 insertions, 6 deletions
diff --git a/refs/files-backend.c b/refs/files-backend.c index dea46d07ae..dfc8e9bc50 100644 --- a/refs/files-backend.c +++ b/refs/files-backend.c @@ -2115,7 +2115,9 @@ static int files_delete_reflog(struct ref_store *ref_store,  	return ret;  } -static int show_one_reflog_ent(struct files_ref_store *refs, struct strbuf *sb, +static int show_one_reflog_ent(struct files_ref_store *refs, +			       const char *refname, +			       struct strbuf *sb,  			       each_reflog_ent_fn fn, void *cb_data)  {  	struct object_id ooid, noid; @@ -2142,7 +2144,7 @@ static int show_one_reflog_ent(struct files_ref_store *refs, struct strbuf *sb,  		message += 6;  	else  		message += 7; -	return fn(&ooid, &noid, p, timestamp, tz, message, cb_data); +	return fn(refname, &ooid, &noid, p, timestamp, tz, message, cb_data);  }  static char *find_beginning_of_line(char *bob, char *scan) @@ -2226,7 +2228,7 @@ static int files_for_each_reflog_ent_reverse(struct ref_store *ref_store,  				strbuf_splice(&sb, 0, 0, bp + 1, endp - (bp + 1));  				scanp = bp;  				endp = bp + 1; -				ret = show_one_reflog_ent(refs, &sb, fn, cb_data); +				ret = show_one_reflog_ent(refs, refname, &sb, fn, cb_data);  				strbuf_reset(&sb);  				if (ret)  					break; @@ -2238,7 +2240,7 @@ static int files_for_each_reflog_ent_reverse(struct ref_store *ref_store,  				 * Process it, and we can end the loop.  				 */  				strbuf_splice(&sb, 0, 0, buf, endp - buf); -				ret = show_one_reflog_ent(refs, &sb, fn, cb_data); +				ret = show_one_reflog_ent(refs, refname, &sb, fn, cb_data);  				strbuf_reset(&sb);  				break;  			} @@ -2288,7 +2290,7 @@ static int files_for_each_reflog_ent(struct ref_store *ref_store,  		return -1;  	while (!ret && !strbuf_getwholeline(&sb, logfp, '\n')) -		ret = show_one_reflog_ent(refs, &sb, fn, cb_data); +		ret = show_one_reflog_ent(refs, refname, &sb, fn, cb_data);  	fclose(logfp);  	strbuf_release(&sb);  	return ret; @@ -3360,7 +3362,8 @@ struct expire_reflog_cb {  		     dry_run:1;  }; -static int expire_reflog_ent(struct object_id *ooid, struct object_id *noid, +static int expire_reflog_ent(const char *refname UNUSED, +			     struct object_id *ooid, struct object_id *noid,  			     const char *email, timestamp_t timestamp, int tz,  			     const char *message, void *cb_data)  {  | 
