summaryrefslogtreecommitdiff
path: root/quote.c
diff options
context:
space:
mode:
authorJiang Xin <worldhello.net@gmail.com>2013-06-25 23:53:46 +0800
committerJunio C Hamano <gitster@pobox.com>2013-06-26 11:22:06 -0700
commite9a820cefde2170840fbcdf7c4b74369988869dc (patch)
tree12024a35f95bb2258f739da70ec6480428054c00 /quote.c
parent39598f9983f759b5e38b9e762c695bad6c89a1b3 (diff)
downloadgit-e9a820cefde2170840fbcdf7c4b74369988869dc.tar.gz
write_name{_quoted_relative,}(): remove redundant parameters
After substitute path_relative() in quote.c with relative_path() from path.c, parameters (such as len and prefix_len) are redundant in function write_name() and write_name_quoted_relative(). The callers have already been audited that the strings they pass are properly NUL terminated and the length they give are the length of the string (or -1 that asks the length to be counted by the callee). Remove these now-redundant parameters. Signed-off-by: Jiang Xin <worldhello.net@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'quote.c')
-rw-r--r--quote.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/quote.c b/quote.c
index ebb835923f..5c8808160e 100644
--- a/quote.c
+++ b/quote.c
@@ -312,8 +312,7 @@ void write_name_quotedpfx(const char *pfx, size_t pfxlen,
fputc(terminator, fp);
}
-void write_name_quoted_relative(const char *name, size_t len,
- const char *prefix, size_t prefix_len,
+void write_name_quoted_relative(const char *name, const char *prefix,
FILE *fp, int terminator)
{
struct strbuf sb = STRBUF_INIT;