{"action":"created","comment":{"url":"https://api.github.com/repos/lxc/lxd/pulls/comments/33086628","id":33086628,"diff_hunk":"@@ -1849,7 +1850,14 @@ func (c *lxdContainer) applyIdmapSet() error {\n }\n \n func (c *lxdContainer) applyDevices() error {\n-\tfor name, d := range c.devices {\n+\tvar keys []string\n+\tfor k := range c.devices {","path":"lxd/containers.go","position":14,"original_position":14,"commit_id":"ddb848fd8f4b3de7736f7a4cfa76c6213f558b7d","original_commit_id":"ddb848fd8f4b3de7736f7a4cfa76c6213f558b7d","user":{"login":"tych0","id":785111,"avatar_url":"https://avatars.githubusercontent.com/u/785111?v=3","gravatar_id":"","url":"https://api.github.com/users/tych0","html_url":"https://github.com/tych0","followers_url":"https://api.github.com/users/tych0/followers","following_url":"https://api.github.com/users/tych0/following{/other_user}","gists_url":"https://api.github.com/users/tych0/gists{/gist_id}","starred_url":"https://api.github.com/users/tych0/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tych0/subscriptions","organizations_url":"https://api.github.com/users/tych0/orgs","repos_url":"https://api.github.com/users/tych0/repos","events_url":"https://api.github.com/users/tych0/events{/privacy}","received_events_url":"https://api.github.com/users/tych0/received_events","type":"User","site_admin":false},"body":"Do you need this bit here, or can you just do `keys := range c.devices`?","created_at":"2015-06-23T20:17:11Z","updated_at":"2015-06-23T20:17:11Z","html_url":"https://github.com/lxc/lxd/pull/784#discussion_r33086628","pull_request_url":"https://api.github.com/repos/lxc/lxd/pulls/784","_links":{"self":{"href":"https://api.github.com/repos/lxc/lxd/pulls/comments/33086628"},"html":{"href":"https://github.com/lxc/lxd/pull/784#discussion_r33086628"},"pull_request":{"href":"https://api.github.com/repos/lxc/lxd/pulls/784"}}},"pull_request":{"url":"https://api.github.com/repos/lxc/lxd/pulls/784","id":38375761,"html_url":"https://github.com/lxc/lxd/pull/784","diff_url":"https://github.com/lxc/lxd/pull/784.diff","patch_url":"https://github.com/lxc/lxd/pull/784.patch","issue_url":"https://api.github.com/repos/lxc/lxd/issues/784","number":784,"state":"open","locked":false,"title":"Sort device entries","user":{"login":"stgraber","id":2230599,"avatar_url":"https://avatars.githubusercontent.com/u/2230599?v=3","gravatar_id":"","url":"https://api.github.com/users/stgraber","html_url":"https://github.com/stgraber","followers_url":"https://api.github.com/users/stgraber/followers","following_url":"https://api.github.com/users/stgraber/following{/other_user}","gists_url":"https://api.github.com/users/stgraber/gists{/gist_id}","starred_url":"https://api.github.com/users/stgraber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stgraber/subscriptions","organizations_url":"https://api.github.com/users/stgraber/orgs","repos_url":"https://api.github.com/users/stgraber/repos","events_url":"https://api.github.com/users/stgraber/events{/privacy}","received_events_url":"https://api.github.com/users/stgraber/received_events","type":"User","site_admin":false},"body":"Closes #734\r\n\r\nSigned-off-by: Stéphane Graber <stgraber@ubuntu.com>","created_at":"2015-06-23T19:53:01Z","updated_at":"2015-06-23T20:17:11Z","closed_at":null,"merged_at":null,"merge_commit_sha":"98b2f864615ac1f12fdb2b2150546067aed82470","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/lxc/lxd/pulls/784/commits","review_comments_url":"https://api.github.com/repos/lxc/lxd/pulls/784/comments","review_comment_url":"https://api.github.com/repos/lxc/lxd/pulls/comments{/number}","comments_url":"https://api.github.com/repos/lxc/lxd/issues/784/comments","statuses_url":"https://api.github.com/repos/lxc/lxd/statuses/ddb848fd8f4b3de7736f7a4cfa76c6213f558b7d","head":{"label":"stgraber:master","ref":"master","sha":"ddb848fd8f4b3de7736f7a4cfa76c6213f558b7d","user":{"login":"stgraber","id":2230599,"avatar_url":"https://avatars.githubusercontent.com/u/2230599?v=3","gravatar_id":"","url":"https://api.github.com/users/stgraber","html_url":"https://github.com/stgraber","followers_url":"https://api.github.com/users/stgraber/followers","following_url":"https://api.github.com/users/stgraber/following{/other_user}","gists_url":"https://api.github.com/users/stgraber/gists{/gist_id}","starred_url":"https://api.github.com/users/stgraber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stgraber/subscriptions","organizations_url":"https://api.github.com/users/stgraber/orgs","repos_url":"https://api.github.com/users/stgraber/repos","events_url":"https://api.github.com/users/stgraber/events{/privacy}","received_events_url":"https://api.github.com/users/stgraber/received_events","type":"User","site_admin":false},"repo":{"id":26225592,"name":"lxd","full_name":"stgraber/lxd","owner":{"login":"stgraber","id":2230599,"avatar_url":"https://avatars.githubusercontent.com/u/2230599?v=3","gravatar_id":"","url":"https://api.github.com/users/stgraber","html_url":"https://github.com/stgraber","followers_url":"https://api.github.com/users/stgraber/followers","following_url":"https://api.github.com/users/stgraber/following{/other_user}","gists_url":"https://api.github.com/users/stgraber/gists{/gist_id}","starred_url":"https://api.github.com/users/stgraber/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stgraber/subscriptions","organizations_url":"https://api.github.com/users/stgraber/orgs","repos_url":"https://api.github.com/users/stgraber/repos","events_url":"https://api.github.com/users/stgraber/events{/privacy}","received_events_url":"https://api.github.com/users/stgraber/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/stgraber/lxd","description":"REST API, command line tool and OpenStack integration plugin for LXC (pronounced lex-dee)","fork":true,"url":"https://api.github.com/repos/stgraber/lxd","forks_url":"https://api.github.com/repos/stgraber/lxd/forks","keys_url":"https://api.github.com/repos/stgraber/lxd/keys{/key_id}","collaborators_url":"https://api.github.com/repos/stgraber/lxd/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/stgraber/lxd/teams","hooks_url":"https://api.github.com/repos/stgraber/lxd/hooks","issue_events_url":"https://api.github.com/repos/stgraber/lxd/issues/events{/number}","events_url":"https://api.github.com/repos/stgraber/lxd/events","assignees_url":"https://api.github.com/repos/stgraber/lxd/assignees{/user}","branches_url":"https://api.github.com/repos/stgraber/lxd/branches{/branch}","tags_url":"https://api.github.com/repos/stgraber/lxd/tags","blobs_url":"https://api.github.com/repos/stgraber/lxd/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/stgraber/lxd/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/stgraber/lxd/git/refs{/sha}","trees_url":"https://api.github.com/repos/stgraber/lxd/git/trees{/sha}","statuses_url":"https://api.github.com/repos/stgraber/lxd/statuses/{sha}","languages_url":"https://api.github.com/repos/stgraber/lxd/languages","stargazers_url":"https://api.github.com/repos/stgraber/lxd/stargazers","contributors_url":"https://api.github.com/repos/stgraber/lxd/contributors","subscribers_url":"https://api.github.com/repos/stgraber/lxd/subscribers","subscription_url":"https://api.github.com/repos/stgraber/lxd/subscription","commits_url":"https://api.github.com/repos/stgraber/lxd/commits{/sha}","git_commits_url":"https://api.github.com/repos/stgraber/lxd/git/commits{/sha}","comments_url":"https://api.github.com/repos/stgraber/lxd/comments{/number}","issue_comment_url":"https://api.github.com/repos/stgraber/lxd/issues/comments{/number}","contents_url":"https://api.github.com/repos/stgraber/lxd/contents/{+path}","compare_url":"https://api.github.com/repos/stgraber/lxd/compare/{base}...{head}","merges_url":"https://api.github.com/repos/stgraber/lxd/merges","archive_url":"https://api.github.com/repos/stgraber/lxd/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/stgraber/lxd/downloads","issues_url":"https://api.github.com/repos/stgraber/lxd/issues{/number}","pulls_url":"https://api.github.com/repos/stgraber/lxd/pulls{/number}","milestones_url":"https://api.github.com/repos/stgraber/lxd/milestones{/number}","notifications_url":"https://api.github.com/repos/stgraber/lxd/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/stgraber/lxd/labels{/name}","releases_url":"https://api.github.com/repos/stgraber/lxd/releases{/id}","created_at":"2014-11-05T15:24:41Z","updated_at":"2015-05-08T19:13:37Z","pushed_at":"2015-06-23T19:52:24Z","git_url":"git://github.com/stgraber/lxd.git","ssh_url":"git@github.com:stgraber/lxd.git","clone_url":"https://github.com/stgraber/lxd.git","svn_url":"https://github.com/stgraber/lxd","homepage":null,"size":3037,"stargazers_count":1,"watchers_count":1,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":1,"default_branch":"master"}},"base":{"label":"lxc:master","ref":"master","sha":"44a827aff7dba6fe96821de574e983a39522bd55","user":{"login":"lxc","id":2301756,"avatar_url":"https://avatars.githubusercontent.com/u/2301756?v=3","gravatar_id":"","url":"https://api.github.com/users/lxc","html_url":"https://github.com/lxc","followers_url":"https://api.github.com/users/lxc/followers","following_url":"https://api.github.com/users/lxc/following{/other_user}","gists_url":"https://api.github.com/users/lxc/gists{/gist_id}","starred_url":"https://api.github.com/users/lxc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lxc/subscriptions","organizations_url":"https://api.github.com/users/lxc/orgs","repos_url":"https://api.github.com/users/lxc/repos","events_url":"https://api.github.com/users/lxc/events{/privacy}","received_events_url":"https://api.github.com/users/lxc/received_events","type":"Organization","site_admin":false},"repo":{"id":26192117,"name":"lxd","full_name":"lxc/lxd","owner":{"login":"lxc","id":2301756,"avatar_url":"https://avatars.githubusercontent.com/u/2301756?v=3","gravatar_id":"","url":"https://api.github.com/users/lxc","html_url":"https://github.com/lxc","followers_url":"https://api.github.com/users/lxc/followers","following_url":"https://api.github.com/users/lxc/following{/other_user}","gists_url":"https://api.github.com/users/lxc/gists{/gist_id}","starred_url":"https://api.github.com/users/lxc/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lxc/subscriptions","organizations_url":"https://api.github.com/users/lxc/orgs","repos_url":"https://api.github.com/users/lxc/repos","events_url":"https://api.github.com/users/lxc/events{/privacy}","received_events_url":"https://api.github.com/users/lxc/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/lxc/lxd","description":"Daemon based on liblxc offering a REST API to manage containers","fork":false,"url":"https://api.github.com/repos/lxc/lxd","forks_url":"https://api.github.com/repos/lxc/lxd/forks","keys_url":"https://api.github.com/repos/lxc/lxd/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lxc/lxd/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lxc/lxd/teams","hooks_url":"https://api.github.com/repos/lxc/lxd/hooks","issue_events_url":"https://api.github.com/repos/lxc/lxd/issues/events{/number}","events_url":"https://api.github.com/repos/lxc/lxd/events","assignees_url":"https://api.github.com/repos/lxc/lxd/assignees{/user}","branches_url":"https://api.github.com/repos/lxc/lxd/branches{/branch}","tags_url":"https://api.github.com/repos/lxc/lxd/tags","blobs_url":"https://api.github.com/repos/lxc/lxd/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lxc/lxd/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lxc/lxd/git/refs{/sha}","trees_url":"https://api.github.com/repos/lxc/lxd/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lxc/lxd/statuses/{sha}","languages_url":"https://api.github.com/repos/lxc/lxd/languages","stargazers_url":"https://api.github.com/repos/lxc/lxd/stargazers","contributors_url":"https://api.github.com/repos/lxc/lxd/contributors","subscribers_url":"https://api.github.com/repos/lxc/lxd/subscribers","subscription_url":"https://api.github.com/repos/lxc/lxd/subscription","commits_url":"https://api.github.com/repos/lxc/lxd/commits{/sha}","git_commits_url":"https://api.github.com/repos/lxc/lxd/git/commits{/sha}","comments_url":"https://api.github.com/repos/lxc/lxd/comments{/number}","issue_comment_url":"https://api.github.com/repos/lxc/lxd/issues/comments{/number}","contents_url":"https://api.github.com/repos/lxc/lxd/contents/{+path}","compare_url":"https://api.github.com/repos/lxc/lxd/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lxc/lxd/merges","archive_url":"https://api.github.com/repos/lxc/lxd/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lxc/lxd/downloads","issues_url":"https://api.github.com/repos/lxc/lxd/issues{/number}","pulls_url":"https://api.github.com/repos/lxc/lxd/pulls{/number}","milestones_url":"https://api.github.com/repos/lxc/lxd/milestones{/number}","notifications_url":"https://api.github.com/repos/lxc/lxd/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lxc/lxd/labels{/name}","releases_url":"https://api.github.com/repos/lxc/lxd/releases{/id}","created_at":"2014-11-04T22:40:52Z","updated_at":"2015-06-23T17:25:51Z","pushed_at":"2015-06-23T20:15:54Z","git_url":"git://github.com/lxc/lxd.git","ssh_url":"git@github.com:lxc/lxd.git","clone_url":"https://github.com/lxc/lxd.git","svn_url":"https://github.com/lxc/lxd","homepage":"https://linuxcontainers.org","size":5089,"stargazers_count":496,"watchers_count":496,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":68,"mirror_url":null,"open_issues_count":61,"forks":68,"open_issues":61,"watchers":496,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/lxc/lxd/pulls/784"},"html":{"href":"https://github.com/lxc/lxd/pull/784"},"issue":{"href":"https://api.github.com/repos/lxc/lxd/issues/784"},"comments":{"href":"https://api.github.com/repos/lxc/lxd/issues/784/comments"},"review_comments":{"href":"https://api.github.com/repos/lxc/lxd/pulls/784/comments"},"review_comment":{"href":"https://api.github.com/repos/lxc/lxd/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/lxc/lxd/pulls/784/commits"},"statuses":{"href":"https://api.github.com/repos/lxc/lxd/statuses/ddb848fd8f4b3de7736f7a4cfa76c6213f558b7d"}}}}