{"action":"created","comment":{"url":"https://api.github.com/repos/ms-iot/lightning/pulls/comments/54500831","id":54500831,"diff_hunk":"@@ -184,37 +184,51 @@ HRESULT GetControllerBaseAddress(PWCHAR deviceName, HANDLE & handle, PVOID & bas\n                         g_openDeviceMask |= 1 << i;\n \n                         IOControlCode^ IOCTL = ref new IOControlCode(0x423, 0x100, IOControlAccessMode::Any, IOControlBufferingMethod::Buffered);\n-                        Buffer^ addressBuffer = ref new Buffer(8);\n+                        Buffer^ addressBuffer = ref new Buffer(sizeof(DMAP_MAPMEMORY_OUTPUT_BUFFER));\n \n                         create_task(device->SendIOControlAsync(IOCTL, nullptr, addressBuffer))\n                             .then([addressBuffer, &controllerAddress, &findCompleted, &hr](UINT32 result)\n                         {\n-                            // We expect a 4-byte address and a 4-byte length to have been transferred \n-                            // into the address buffer by the I/O operation.\n+                            // We expect an 8-byte address and a 4-byte length to have been transferred \n+                            // into the address buffer by the I/O operation.  If this is an old driver, \n+                            // we could get a 4-byte address and a 4-byte length instead.\n \n-                            // hr should already be S_OK \n-                            if (result == 8)\n+                            if (result < 8)\n                             {\n-                                hr = S_OK;\n+                                hr = E_FAIL;","path":"source/DmapSupport.cpp","position":30,"original_position":30,"commit_id":"acc3459134460318df6080827c6692b427cedebc","original_commit_id":"acc3459134460318df6080827c6692b427cedebc","user":{"login":"ooeygui","id":4564624,"avatar_url":"https://avatars.githubusercontent.com/u/4564624?v=3","gravatar_id":"","url":"https://api.github.com/users/ooeygui","html_url":"https://github.com/ooeygui","followers_url":"https://api.github.com/users/ooeygui/followers","following_url":"https://api.github.com/users/ooeygui/following{/other_user}","gists_url":"https://api.github.com/users/ooeygui/gists{/gist_id}","starred_url":"https://api.github.com/users/ooeygui/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ooeygui/subscriptions","organizations_url":"https://api.github.com/users/ooeygui/orgs","repos_url":"https://api.github.com/users/ooeygui/repos","events_url":"https://api.github.com/users/ooeygui/events{/privacy}","received_events_url":"https://api.github.com/users/ooeygui/received_events","type":"User","site_admin":false},"body":"Is there a better error code?","created_at":"2016-02-29T23:51:50Z","updated_at":"2016-02-29T23:51:50Z","html_url":"https://github.com/ms-iot/lightning/pull/29#discussion_r54500831","pull_request_url":"https://api.github.com/repos/ms-iot/lightning/pulls/29","_links":{"self":{"href":"https://api.github.com/repos/ms-iot/lightning/pulls/comments/54500831"},"html":{"href":"https://github.com/ms-iot/lightning/pull/29#discussion_r54500831"},"pull_request":{"href":"https://api.github.com/repos/ms-iot/lightning/pulls/29"}}},"pull_request":{"url":"https://api.github.com/repos/ms-iot/lightning/pulls/29","id":57304186,"html_url":"https://github.com/ms-iot/lightning/pull/29","diff_url":"https://github.com/ms-iot/lightning/pull/29.diff","patch_url":"https://github.com/ms-iot/lightning/pull/29.patch","issue_url":"https://api.github.com/repos/ms-iot/lightning/issues/29","number":29,"state":"open","locked":false,"title":"Hardware interrupt support for PI2 and MBM.","user":{"login":"JustAddWires","id":7936921,"avatar_url":"https://avatars.githubusercontent.com/u/7936921?v=3","gravatar_id":"","url":"https://api.github.com/users/JustAddWires","html_url":"https://github.com/JustAddWires","followers_url":"https://api.github.com/users/JustAddWires/followers","following_url":"https://api.github.com/users/JustAddWires/following{/other_user}","gists_url":"https://api.github.com/users/JustAddWires/gists{/gist_id}","starred_url":"https://api.github.com/users/JustAddWires/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JustAddWires/subscriptions","organizations_url":"https://api.github.com/users/JustAddWires/orgs","repos_url":"https://api.github.com/users/JustAddWires/repos","events_url":"https://api.github.com/users/JustAddWires/events{/privacy}","received_events_url":"https://api.github.com/users/JustAddWires/received_events","type":"User","site_admin":false},"body":"","created_at":"2016-01-27T02:10:51Z","updated_at":"2016-02-29T23:51:51Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e23cda36790e462415986482533ca169ba689593","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/ms-iot/lightning/pulls/29/commits","review_comments_url":"https://api.github.com/repos/ms-iot/lightning/pulls/29/comments","review_comment_url":"https://api.github.com/repos/ms-iot/lightning/pulls/comments{/number}","comments_url":"https://api.github.com/repos/ms-iot/lightning/issues/29/comments","statuses_url":"https://api.github.com/repos/ms-iot/lightning/statuses/acc3459134460318df6080827c6692b427cedebc","head":{"label":"JustAddWires:develop","ref":"develop","sha":"acc3459134460318df6080827c6692b427cedebc","user":{"login":"JustAddWires","id":7936921,"avatar_url":"https://avatars.githubusercontent.com/u/7936921?v=3","gravatar_id":"","url":"https://api.github.com/users/JustAddWires","html_url":"https://github.com/JustAddWires","followers_url":"https://api.github.com/users/JustAddWires/followers","following_url":"https://api.github.com/users/JustAddWires/following{/other_user}","gists_url":"https://api.github.com/users/JustAddWires/gists{/gist_id}","starred_url":"https://api.github.com/users/JustAddWires/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JustAddWires/subscriptions","organizations_url":"https://api.github.com/users/JustAddWires/orgs","repos_url":"https://api.github.com/users/JustAddWires/repos","events_url":"https://api.github.com/users/JustAddWires/events{/privacy}","received_events_url":"https://api.github.com/users/JustAddWires/received_events","type":"User","site_admin":false},"repo":{"id":44341685,"name":"lightning","full_name":"JustAddWires/lightning","owner":{"login":"JustAddWires","id":7936921,"avatar_url":"https://avatars.githubusercontent.com/u/7936921?v=3","gravatar_id":"","url":"https://api.github.com/users/JustAddWires","html_url":"https://github.com/JustAddWires","followers_url":"https://api.github.com/users/JustAddWires/followers","following_url":"https://api.github.com/users/JustAddWires/following{/other_user}","gists_url":"https://api.github.com/users/JustAddWires/gists{/gist_id}","starred_url":"https://api.github.com/users/JustAddWires/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/JustAddWires/subscriptions","organizations_url":"https://api.github.com/users/JustAddWires/orgs","repos_url":"https://api.github.com/users/JustAddWires/repos","events_url":"https://api.github.com/users/JustAddWires/events{/privacy}","received_events_url":"https://api.github.com/users/JustAddWires/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/JustAddWires/lightning","description":"","fork":true,"url":"https://api.github.com/repos/JustAddWires/lightning","forks_url":"https://api.github.com/repos/JustAddWires/lightning/forks","keys_url":"https://api.github.com/repos/JustAddWires/lightning/keys{/key_id}","collaborators_url":"https://api.github.com/repos/JustAddWires/lightning/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/JustAddWires/lightning/teams","hooks_url":"https://api.github.com/repos/JustAddWires/lightning/hooks","issue_events_url":"https://api.github.com/repos/JustAddWires/lightning/issues/events{/number}","events_url":"https://api.github.com/repos/JustAddWires/lightning/events","assignees_url":"https://api.github.com/repos/JustAddWires/lightning/assignees{/user}","branches_url":"https://api.github.com/repos/JustAddWires/lightning/branches{/branch}","tags_url":"https://api.github.com/repos/JustAddWires/lightning/tags","blobs_url":"https://api.github.com/repos/JustAddWires/lightning/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/JustAddWires/lightning/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/JustAddWires/lightning/git/refs{/sha}","trees_url":"https://api.github.com/repos/JustAddWires/lightning/git/trees{/sha}","statuses_url":"https://api.github.com/repos/JustAddWires/lightning/statuses/{sha}","languages_url":"https://api.github.com/repos/JustAddWires/lightning/languages","stargazers_url":"https://api.github.com/repos/JustAddWires/lightning/stargazers","contributors_url":"https://api.github.com/repos/JustAddWires/lightning/contributors","subscribers_url":"https://api.github.com/repos/JustAddWires/lightning/subscribers","subscription_url":"https://api.github.com/repos/JustAddWires/lightning/subscription","commits_url":"https://api.github.com/repos/JustAddWires/lightning/commits{/sha}","git_commits_url":"https://api.github.com/repos/JustAddWires/lightning/git/commits{/sha}","comments_url":"https://api.github.com/repos/JustAddWires/lightning/comments{/number}","issue_comment_url":"https://api.github.com/repos/JustAddWires/lightning/issues/comments{/number}","contents_url":"https://api.github.com/repos/JustAddWires/lightning/contents/{+path}","compare_url":"https://api.github.com/repos/JustAddWires/lightning/compare/{base}...{head}","merges_url":"https://api.github.com/repos/JustAddWires/lightning/merges","archive_url":"https://api.github.com/repos/JustAddWires/lightning/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/JustAddWires/lightning/downloads","issues_url":"https://api.github.com/repos/JustAddWires/lightning/issues{/number}","pulls_url":"https://api.github.com/repos/JustAddWires/lightning/pulls{/number}","milestones_url":"https://api.github.com/repos/JustAddWires/lightning/milestones{/number}","notifications_url":"https://api.github.com/repos/JustAddWires/lightning/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/JustAddWires/lightning/labels{/name}","releases_url":"https://api.github.com/repos/JustAddWires/lightning/releases{/id}","deployments_url":"https://api.github.com/repos/JustAddWires/lightning/deployments","created_at":"2015-10-15T19:54:37Z","updated_at":"2016-01-27T02:02:09Z","pushed_at":"2016-02-11T21:15:47Z","git_url":"git://github.com/JustAddWires/lightning.git","ssh_url":"git@github.com:JustAddWires/lightning.git","clone_url":"https://github.com/JustAddWires/lightning.git","svn_url":"https://github.com/JustAddWires/lightning","homepage":null,"size":1233,"stargazers_count":0,"watchers_count":0,"language":"C++","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":0,"default_branch":"develop"}},"base":{"label":"ms-iot:develop","ref":"develop","sha":"f85b5af309dcee48971a2dd95d5fd29428bf3bde","user":{"login":"ms-iot","id":7927770,"avatar_url":"https://avatars.githubusercontent.com/u/7927770?v=3","gravatar_id":"","url":"https://api.github.com/users/ms-iot","html_url":"https://github.com/ms-iot","followers_url":"https://api.github.com/users/ms-iot/followers","following_url":"https://api.github.com/users/ms-iot/following{/other_user}","gists_url":"https://api.github.com/users/ms-iot/gists{/gist_id}","starred_url":"https://api.github.com/users/ms-iot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ms-iot/subscriptions","organizations_url":"https://api.github.com/users/ms-iot/orgs","repos_url":"https://api.github.com/users/ms-iot/repos","events_url":"https://api.github.com/users/ms-iot/events{/privacy}","received_events_url":"https://api.github.com/users/ms-iot/received_events","type":"Organization","site_admin":false},"repo":{"id":43386233,"name":"lightning","full_name":"ms-iot/lightning","owner":{"login":"ms-iot","id":7927770,"avatar_url":"https://avatars.githubusercontent.com/u/7927770?v=3","gravatar_id":"","url":"https://api.github.com/users/ms-iot","html_url":"https://github.com/ms-iot","followers_url":"https://api.github.com/users/ms-iot/followers","following_url":"https://api.github.com/users/ms-iot/following{/other_user}","gists_url":"https://api.github.com/users/ms-iot/gists{/gist_id}","starred_url":"https://api.github.com/users/ms-iot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ms-iot/subscriptions","organizations_url":"https://api.github.com/users/ms-iot/orgs","repos_url":"https://api.github.com/users/ms-iot/repos","events_url":"https://api.github.com/users/ms-iot/events{/privacy}","received_events_url":"https://api.github.com/users/ms-iot/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/ms-iot/lightning","description":"","fork":false,"url":"https://api.github.com/repos/ms-iot/lightning","forks_url":"https://api.github.com/repos/ms-iot/lightning/forks","keys_url":"https://api.github.com/repos/ms-iot/lightning/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ms-iot/lightning/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ms-iot/lightning/teams","hooks_url":"https://api.github.com/repos/ms-iot/lightning/hooks","issue_events_url":"https://api.github.com/repos/ms-iot/lightning/issues/events{/number}","events_url":"https://api.github.com/repos/ms-iot/lightning/events","assignees_url":"https://api.github.com/repos/ms-iot/lightning/assignees{/user}","branches_url":"https://api.github.com/repos/ms-iot/lightning/branches{/branch}","tags_url":"https://api.github.com/repos/ms-iot/lightning/tags","blobs_url":"https://api.github.com/repos/ms-iot/lightning/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ms-iot/lightning/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ms-iot/lightning/git/refs{/sha}","trees_url":"https://api.github.com/repos/ms-iot/lightning/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ms-iot/lightning/statuses/{sha}","languages_url":"https://api.github.com/repos/ms-iot/lightning/languages","stargazers_url":"https://api.github.com/repos/ms-iot/lightning/stargazers","contributors_url":"https://api.github.com/repos/ms-iot/lightning/contributors","subscribers_url":"https://api.github.com/repos/ms-iot/lightning/subscribers","subscription_url":"https://api.github.com/repos/ms-iot/lightning/subscription","commits_url":"https://api.github.com/repos/ms-iot/lightning/commits{/sha}","git_commits_url":"https://api.github.com/repos/ms-iot/lightning/git/commits{/sha}","comments_url":"https://api.github.com/repos/ms-iot/lightning/comments{/number}","issue_comment_url":"https://api.github.com/repos/ms-iot/lightning/issues/comments{/number}","contents_url":"https://api.github.com/repos/ms-iot/lightning/contents/{+path}","compare_url":"https://api.github.com/repos/ms-iot/lightning/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ms-iot/lightning/merges","archive_url":"https://api.github.com/repos/ms-iot/lightning/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ms-iot/lightning/downloads","issues_url":"https://api.github.com/repos/ms-iot/lightning/issues{/number}","pulls_url":"https://api.github.com/repos/ms-iot/lightning/pulls{/number}","milestones_url":"https://api.github.com/repos/ms-iot/lightning/milestones{/number}","notifications_url":"https://api.github.com/repos/ms-iot/lightning/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ms-iot/lightning/labels{/name}","releases_url":"https://api.github.com/repos/ms-iot/lightning/releases{/id}","deployments_url":"https://api.github.com/repos/ms-iot/lightning/deployments","created_at":"2015-09-29T18:27:30Z","updated_at":"2016-02-12T00:51:24Z","pushed_at":"2016-02-11T21:15:47Z","git_url":"git://github.com/ms-iot/lightning.git","ssh_url":"git@github.com:ms-iot/lightning.git","clone_url":"https://github.com/ms-iot/lightning.git","svn_url":"https://github.com/ms-iot/lightning","homepage":null,"size":1178,"stargazers_count":3,"watchers_count":3,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":5,"mirror_url":null,"open_issues_count":8,"forks":5,"open_issues":8,"watchers":3,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/ms-iot/lightning/pulls/29"},"html":{"href":"https://github.com/ms-iot/lightning/pull/29"},"issue":{"href":"https://api.github.com/repos/ms-iot/lightning/issues/29"},"comments":{"href":"https://api.github.com/repos/ms-iot/lightning/issues/29/comments"},"review_comments":{"href":"https://api.github.com/repos/ms-iot/lightning/pulls/29/comments"},"review_comment":{"href":"https://api.github.com/repos/ms-iot/lightning/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/ms-iot/lightning/pulls/29/commits"},"statuses":{"href":"https://api.github.com/repos/ms-iot/lightning/statuses/acc3459134460318df6080827c6692b427cedebc"}}}}