Thread (43 messages) 43 messages, 4 authors, 2016-12-03

Re: [PATCH 14/16] checkout: recurse into submodules if asked to

From: Brandon Williams <hidden>
Date: 2016-11-16 00:33:55

On 11/15, Stefan Beller wrote:
+int option_parse_recurse_submodules(const struct option *opt,
+				    const char *arg, int unset)
+{
+	if (unset) {
+		recurse_submodules = RECURSE_SUBMODULES_OFF;
+		return 0;
+	}
+	if (arg)
+		recurse_submodules =
+			parse_update_recurse_submodules_arg(opt->long_name,
+							    arg);
+	else
+		recurse_submodules = RECURSE_SUBMODULES_ON;
+
+	return 0;
+}
I assume it is ok to always return 0 from this function?  Also, I know
we don't like having braces on single statement if's but it is a bit
hard to read that multi-line statement without braces.  But that's just
my opinion :)


-- 
Brandon Williams
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help