{"thread":{"id":"41693","subject":"[PATCH] submodule-config: use hashmap_iter_init()","startedAt":"2016-03-15T18:25:30Z","lastAt":"2016-03-15T19:10:18Z","messageCount":4,"participants":["Alexander Kuleshov","Eric Sunshine","Stefan Beller"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"280815","messageId":"1458066330-5107-1-git-send-email-kuleshovmail@gmail.com","threadId":"41693","inReplyTo":null,"subject":"[PATCH] submodule-config: use hashmap_iter_init()","fromName":"Alexander Kuleshov","fromEmail":"kuleshovmail@gmail.com","sentAt":"2016-03-15T18:25:30Z","receivedAt":"2016-03-15T18:25:30Z","isPatch":true,"sender":{"key":"kuleshovmail@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2699235?v=4"},"body":"from the <hashmap.h> for simplification.\n---\n submodule-config.c | 3 +--\n 1 file changed, 1 insertion(+), 2 deletions(-)\n\ndiff --git a/submodule-config.c b/submodule-config.c\nindex b82d1fb..8ac5031 100644\n--- a/submodule-config.c\n+++ b/submodule-config.c\n@@ -405,8 +405,7 @@ static const struct submodule *config_from(struct submodule_cache *cache,\n \t\tstruct hashmap_iter iter;\n \t\tstruct submodule_entry *entry;\n \n-\t\thashmap_iter_init(&cache->for_name, &iter);\n-\t\tentry = hashmap_iter_next(&iter);\n+\t\tentry = hashmap_iter_first(&cache->for_name, &iter);\n \t\tif (!entry)\n \t\t\treturn NULL;\n \t\treturn entry->config;\n-- \n2.8.0.rc2.216.g1477fb2.dirty\n"},{"id":"280817","messageId":"CAPig+cR6Cy2MHvoTxNa89gZx9qJZW1Rv93N+wcwK2JRGkUBzRw@mail.gmail.com","threadId":"41693","inReplyTo":"1458066330-5107-1-git-send-email-kuleshovmail@gmail.com","subject":"Re: [PATCH] submodule-config: use hashmap_iter_init()","fromName":"Eric Sunshine","fromEmail":"sunshine@sunshineco.com","sentAt":"2016-03-15T18:58:05Z","receivedAt":"2016-03-15T18:58:05Z","isPatch":true,"sender":{"key":"sunshine@sunshineco.com","avatar":"https://avatars.githubusercontent.com/u/163641?v=4"},"body":"On Tue, Mar 15, 2016 at 2:25 PM, Alexander Kuleshov\n<kuleshovmail@gmail.com> wrote:\n> submodule-config: use hashmap_iter_init()\n\nDid you mean s/init/first/ ?\n\n> from the <hashmap.h> for simplification.\n\nSentence fragment...\n\nMissing sign-off.\n\n> ---\n> diff --git a/submodule-config.c b/submodule-config.c\n> index b82d1fb..8ac5031 100644\n> --- a/submodule-config.c\n> +++ b/submodule-config.c\n> @@ -405,8 +405,7 @@ static const struct submodule *config_from(struct submodule_cache *cache,\n>                 struct hashmap_iter iter;\n>                 struct submodule_entry *entry;\n>\n> -               hashmap_iter_init(&cache->for_name, &iter);\n> -               entry = hashmap_iter_next(&iter);\n> +               entry = hashmap_iter_first(&cache->for_name, &iter);\n>                 if (!entry)\n>                         return NULL;\n>                 return entry->config;\n> --\n"},{"id":"280819","messageId":"CAGZ79kZH_xzfvo=cP_+BdsqpthwQUKkJjo7OawkpFN9y+jm_+w@mail.gmail.com","threadId":"41693","inReplyTo":"CAPig+cR6Cy2MHvoTxNa89gZx9qJZW1Rv93N+wcwK2JRGkUBzRw@mail.gmail.com","subject":"Re: [PATCH] submodule-config: use hashmap_iter_init()","fromName":"Stefan Beller","fromEmail":"sbeller@google.com","sentAt":"2016-03-15T19:08:31Z","receivedAt":"2016-03-15T19:08:31Z","isPatch":true,"sender":{"key":"stefanbeller@gmail.com","avatar":"https://avatars.githubusercontent.com/u/455868?v=4"},"body":"On Tue, Mar 15, 2016 at 11:58 AM, Eric Sunshine <sunshine@sunshineco.com> wrote:\n> On Tue, Mar 15, 2016 at 2:25 PM, Alexander Kuleshov\n> <kuleshovmail@gmail.com> wrote:\n>> submodule-config: use hashmap_iter_init()\n>\n> Did you mean s/init/first/ ?\n>\n>> from the <hashmap.h> for simplification.\n>\n> Sentence fragment...\n>\n> Missing sign-off.\n>\n>> ---\n>> diff --git a/submodule-config.c b/submodule-config.c\n>> index b82d1fb..8ac5031 100644\n>> --- a/submodule-config.c\n>> +++ b/submodule-config.c\n>> @@ -405,8 +405,7 @@ static const struct submodule *config_from(struct submodule_cache *cache,\n>>                 struct hashmap_iter iter;\n>>                 struct submodule_entry *entry;\n>>\n>> -               hashmap_iter_init(&cache->for_name, &iter);\n>> -               entry = hashmap_iter_next(&iter);\n>> +               entry = hashmap_iter_first(&cache->for_name, &iter);\n\nThe change looks correct to me. But as Eric said, the commit message\nneeds work and a sign off. With that,\nReviewed-by: Stefan Beller <sbeller@google.com>\n\nThanks,\nStefan\n"},{"id":"280820","messageId":"CANCZXo7OBe_+udjGXQbe6YpZK8Ln113J=PZ59MnwQq7E8jwYLA@mail.gmail.com","threadId":"41693","inReplyTo":"CAGZ79kZH_xzfvo=cP_+BdsqpthwQUKkJjo7OawkpFN9y+jm_+w@mail.gmail.com","subject":"Re: [PATCH] submodule-config: use hashmap_iter_init()","fromName":"Alexander Kuleshov","fromEmail":"kuleshovmail@gmail.com","sentAt":"2016-03-15T19:10:18Z","receivedAt":"2016-03-15T19:10:18Z","isPatch":true,"sender":{"key":"kuleshovmail@gmail.com","avatar":"https://avatars.githubusercontent.com/u/2699235?v=4"},"body":"On Wed, Mar 16, 2016 at 1:08 AM, Stefan Beller <sbeller@google.com> wrote:\n> The change looks correct to me. But as Eric said, the commit message\n> needs work and a sign off. With that,\n> Reviewed-by: Stefan Beller <sbeller@google.com>\n\nAh, yes, forgot to pass `-s` to commit command. Sorry for noise guys,\nwill resend\nthe patch.\n"}]}