aboutsummaryrefslogtreecommitdiff
path: root/ui-clone.c
diff refs
from: back
to: back
| flip
diff options
context:
space:
mode:
Diffstat (limited to 'ui-clone.c')
-rw-r--r--ui-clone.c12
1 files changed, 3 insertions, 9 deletions
diff --git a/ui-clone.c b/ui-clone.c
index 2ed3e1c..31989a5 100644
--- a/ui-clone.c
+++ b/ui-clone.c
@@ -95,7 +95,7 @@ void cgit_clone_info(void)
void cgit_clone_objects(void)
{
- char *p, *path;
+ char *p;
if (!ctx.qry.path)
goto err;
@@ -116,9 +116,7 @@ void cgit_clone_objects(void)
goto err;
}
- path = repo_git_path(the_repository, "objects/%s", ctx.qry.path);
- send_file(path);
- free(path);
+ send_file(git_path("objects/%s", ctx.qry.path));
return;
err:
@@ -127,9 +125,5 @@ err:
void cgit_clone_head(void)
{
- char *path;
-
- path = repo_git_path(the_repository, "HEAD");
- send_file(path);
- free(path);
+ send_file(git_path("%s", "HEAD"));
}