Andrew's git
/
gitweb.git
/ diff
summary
|
log
|
commit
| diff |
tree
commit
grep
author
committer
pickaxe
?
re
resolve_gitlink_ref(): eliminate temporary variable
author
Michael Haggerty
<mhagger@alum.mit.edu>
Sun, 4 Sep 2016 16:08:07 +0000
(18:08 +0200)
committer
Junio C Hamano
<gitster@pobox.com>
Fri, 9 Sep 2016 22:28:12 +0000
(15:28 -0700)
Signed-off-by: Michael Haggerty <mhagger@alum.mit.edu>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
refs/files-backend.c
patch
|
blob
|
history
raw
|
patch
| inline |
side by side
(parent:
2880d16
)
diff --git
a/refs/files-backend.c
b/refs/files-backend.c
index a9ca003bae114abb67010cd1798e89eddab4060f..d56fc15163e6b5a7b7ceaa0aaa957a4af30ac325 100644
(file)
--- a/
refs/files-backend.c
+++ b/
refs/files-backend.c
@@
-1387,7
+1387,7
@@
static int resolve_gitlink_ref_recursive(struct ref_cache *refs,
int resolve_gitlink_ref(const char *path, const char *refname, unsigned char *sha1)
{
- int len = strlen(path)
, retval
;
+ int len = strlen(path);
struct strbuf submodule = STRBUF_INIT;
struct ref_cache *refs;
@@
-1404,8
+1404,7
@@
int resolve_gitlink_ref(const char *path, const char *refname, unsigned char *sh
}
strbuf_release(&submodule);
- retval = resolve_gitlink_ref_recursive(refs, refname, sha1, 0);
- return retval;
+ return resolve_gitlink_ref_recursive(refs, refname, sha1, 0);
}
/*