{"thread":{"id":"40240","subject":"[PATCH] path.c: make 'common_list' a file local symbol","startedAt":"2015-09-01T15:54:09Z","lastAt":"2015-09-01T18:06:07Z","messageCount":2,"participants":["Ramsay Jones","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"269097","messageId":"55E5CA21.5080306@ramsayjones.plus.com","threadId":"40240","inReplyTo":null,"subject":"[PATCH] path.c: make 'common_list' a file local symbol","fromName":"Ramsay Jones","fromEmail":"ramsay@ramsayjones.plus.com","sentAt":"2015-09-01T15:54:09Z","receivedAt":"2015-09-01T15:54:09Z","isPatch":true,"sender":{"key":"ramsay@ramsayjones.plus.com","avatar":"https://avatars.githubusercontent.com/u/33702710?v=4"},"body":"\nCommit 04afda89 (\"refs: clean up common_list\", 26-08-2015) changed\nthe type of the 'common_list' symbol from an array of 'formatted'\nstrings to an array of struct containing the same data. However, in\naddition it also (inadvertently) changed the visibility of the\nsymbol from file local to external.\n\nIn order to revert the visibility of the symbol to file local, add\nthe static modifier to the declaration of 'common_list'.\n\nNoticed by sparse (symbol 'common_list' was not declared. Should it\nbe static?).\n\nSigned-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>\n---\n\nHi David,\n\nIf you need to re-roll the patches on your 'dt/refs-bisection' branch, could you\nplease squash this into the relevant patch.\n\nThanks!\n\nATB,\nRamsay Jones\n\n path.c | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/path.c b/path.c\nindex 9d32d19..a80eaf7 100644\n--- a/path.c\n+++ b/path.c\n@@ -100,7 +100,7 @@ struct common_dir {\n     const char *dirname;\n };\n \n-struct common_dir common_list[] = {\n+static struct common_dir common_list[] = {\n     { 0, 1, 0, \"branches\" },\n     { 0, 1, 0, \"hooks\" },\n     { 0, 1, 0, \"info\" },\n-- \n2.5.0\n"},{"id":"269117","messageId":"xmqqegiirp4g.fsf@gitster.mtv.corp.google.com","threadId":"40240","inReplyTo":"55E5CA21.5080306@ramsayjones.plus.com","subject":"Re: [PATCH] path.c: make 'common_list' a file local symbol","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2015-09-01T18:06:07Z","receivedAt":"2015-09-01T18:06:07Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Ramsay Jones <ramsay@ramsayjones.plus.com> writes:\n\n> Commit 04afda89 (\"refs: clean up common_list\", 26-08-2015) changed\n> the type of the 'common_list' symbol from an array of 'formatted'\n> strings to an array of struct containing the same data. However, in\n> addition it also (inadvertently) changed the visibility of the\n> symbol from file local to external.\n>\n> In order to revert the visibility of the symbol to file local, add\n> the static modifier to the declaration of 'common_list'.\n>\n> Noticed by sparse (symbol 'common_list' was not declared. Should it\n> be static?).\n>\n> Signed-off-by: Ramsay Jones <ramsay@ramsayjones.plus.com>\n> ---\n>\n> Hi David,\n>\n> If you need to re-roll the patches on your 'dt/refs-bisection' branch, could you\n> please squash this into the relevant patch.\n>\n> Thanks!\n\nThanks.  I've squashed this into David's [v5 1/3] while queuing.\n\n>\n> ATB,\n> Ramsay Jones\n>\n>  path.c | 2 +-\n>  1 file changed, 1 insertion(+), 1 deletion(-)\n>\n> diff --git a/path.c b/path.c\n> index 9d32d19..a80eaf7 100644\n> --- a/path.c\n> +++ b/path.c\n> @@ -100,7 +100,7 @@ struct common_dir {\n>      const char *dirname;\n>  };\n>  \n> -struct common_dir common_list[] = {\n> +static struct common_dir common_list[] = {\n>      { 0, 1, 0, \"branches\" },\n>      { 0, 1, 0, \"hooks\" },\n>      { 0, 1, 0, \"info\" },\n"}]}