Thread (31 messages) flat view 31 messages, 3 authors, 2016-06-15
STALE3743d

[PATCH 18/21] get_default_remote(): remove unneeded flag variable

From: Michael Haggerty <hidden>
Date: 2016-06-15 23:08:54
Subsystem: the rest · Maintainer: Linus Torvalds

It is never read, so we can pass NULL to resolve_ref_unsafe().

Signed-off-by: Michael Haggerty <redacted>
---
 builtin/submodule--helper.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/builtin/submodule--helper.c b/builtin/submodule--helper.c
index ed4f60b..c72365e 100644
--- a/builtin/submodule--helper.c
+++ b/builtin/submodule--helper.c
@@ -17,9 +17,8 @@ static char *get_default_remote(void)
 {
 	char *dest = NULL, *ret;
 	unsigned char sha1[20];
-	int flag = 0;
 	struct strbuf sb = STRBUF_INIT;
-	const char *refname = resolve_ref_unsafe("HEAD", 0, sha1, &flag);
+	const char *refname = resolve_ref_unsafe("HEAD", 0, sha1, NULL);
 
 	if (!refname)
 		die("No such ref: HEAD");
-- 
2.8.0.rc3
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help