{"thread":{"id":"32626","subject":"[PATCH] builtin/reset.c: Fix a sparse warning","startedAt":"2013-01-14T19:28:59Z","lastAt":"2013-01-14T19:35:36Z","messageCount":2,"participants":["Ramsay Jones","Martin von Zweigbergk"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"206829","messageId":"50F45C7B.9030608@ramsay1.demon.co.uk","threadId":"32626","inReplyTo":null,"subject":"[PATCH] builtin/reset.c: Fix a sparse warning","fromName":"Ramsay Jones","fromEmail":"ramsay@ramsay1.demon.co.uk","sentAt":"2013-01-14T19:28:59Z","receivedAt":"2013-01-14T19:28:59Z","isPatch":true,"sender":{"key":"ramsay@ramsayjones.plus.com","avatar":"https://avatars.githubusercontent.com/u/33702710?v=4"},"body":"\nIn particular, sparse issues an \"symbol not declared. Should it be\nstatic?\" warning for the 'parse_args' function. Since this function\ndoes not require greater than file visibility, we suppress this\nwarning by simply adding the static modifier to it's decalaration.\n\nSigned-off-by: Ramsay Jones <ramsay@ramsay1.demon.co.uk>\n---\n\nHi Martin,\n\nWhen you re-roll your \"reset\" patches (branch 'mz/reset-misc'), could\nyou please squash this into commit b24b3654 (\"reset.c: extract function\nfor parsing arguments\", 09-01-2013). Note that this patch is on top of\nthe pu branch (@75ea4ed3), which includes Junio's style fix patch\n(commit 9f45c39f, \"[SQUASH???] style fix\", 10-01-2013).\n\nThanks!\n\nATB,\nRamsay Jones\n\n builtin/reset.c | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/builtin/reset.c b/builtin/reset.c\nindex a37044e..c69f9da 100644\n--- a/builtin/reset.c\n+++ b/builtin/reset.c\n@@ -171,7 +171,7 @@ static void die_if_unmerged_cache(int reset_type)\n \n }\n \n-const char **parse_args(int argc, const char **argv, const char *prefix, const char **rev_ret)\n+static const char **parse_args(int argc, const char **argv, const char *prefix, const char **rev_ret)\n {\n \tconst char *rev = \"HEAD\";\n \tunsigned char unused[20];\n-- \n1.8.1\n"},{"id":"206830","messageId":"CANiSa6iaZQnoX4bGGLi1UFDr3EUeNgMf2FKvryWd9+yySJXKUA@mail.gmail.com","threadId":"32626","inReplyTo":"50F45C7B.9030608@ramsay1.demon.co.uk","subject":"Re: [PATCH] builtin/reset.c: Fix a sparse warning","fromName":"Martin von Zweigbergk","fromEmail":"martinvonz@gmail.com","sentAt":"2013-01-14T19:35:36Z","receivedAt":"2013-01-14T19:35:36Z","isPatch":true,"sender":{"key":"martinvonz@gmail.com","avatar":"https://avatars.githubusercontent.com/u/891642?v=4"},"body":"On Mon, Jan 14, 2013 at 11:28 AM, Ramsay Jones\n<ramsay@ramsay1.demon.co.uk> wrote:\n>\n> In particular, sparse issues an \"symbol not declared. Should it be\n> static?\" warning for the 'parse_args' function. Since this function\n> does not require greater than file visibility, we suppress this\n> warning by simply adding the static modifier to it's decalaration.\n\nOops, how did I miss that? Will fix in re-roll. Thanks.\n\nMartin\n"}]}