Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'quote.c')
-rw-r--r--quote.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/quote.c b/quote.c
index 64ff344158..ebb835923f 100644
--- a/quote.c
+++ b/quote.c
@@ -325,8 +325,8 @@ void write_name_quoted_relative(const char *name, size_t len,
}
/* quote path as relative to the given prefix */
-char *quote_path_relative(const char *in, int len,
- struct strbuf *out, const char *prefix)
+char *quote_path_relative(const char *in, const char *prefix,
+ struct strbuf *out)
{
struct strbuf sb = STRBUF_INIT;
const char *rel = relative_path(in, prefix, &sb);
@@ -334,9 +334,6 @@ char *quote_path_relative(const char *in, int len,
quote_c_style_counted(rel, strlen(rel), out, NULL, 0);
strbuf_release(&sb);
- if (!out->len)
- strbuf_addstr(out, "./");
-
return out->buf;
}