{"action":"created","comment":{"url":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/comments/190532960","pull_request_review_id":122922981,"id":190532960,"diff_hunk":"@@ -101,6 +86,37 @@ ssize_t nanocoap_get(sock_udp_ep_t *remote, const char *path, uint8_t *buf, size\n     return res;\n }\n \n+ssize_t nanocoap_get(sock_udp_ep_t *remote, const char *path, uint8_t *buf, size_t len)\n+{\n+    ssize_t res;\n+    coap_pkt_t pkt;\n+    uint8_t *pktpos = buf;\n+\n+    pkt.hdr = (coap_hdr_t*)buf;\n+    pktpos += coap_build_hdr(pkt.hdr, COAP_REQ, NULL, 0, COAP_METHOD_GET, 1);\n+    pktpos += coap_put_option_uri(pktpos, 0, path, COAP_OPT_URI_PATH);\n+    pkt.payload_len = pktpos - buf;\n+\n+    res = nanocoap_request(&pkt, remote, len);\n+    if (res < 0)\n+    {\n+        return res;\n+    }\n+    else {\n+        res = coap_get_code(&pkt);","path":"sys/net/application_layer/nanocoap/sock.c","position":79,"original_position":79,"commit_id":"391c4fb67644135c045ab2a4ccb5d0ae25a758ec","original_commit_id":"391c4fb67644135c045ab2a4ccb5d0ae25a758ec","user":{"login":"smlng","id":10532675,"avatar_url":"https://avatars1.githubusercontent.com/u/10532675?v=4","gravatar_id":"","url":"https://api.github.com/users/smlng","html_url":"https://github.com/smlng","followers_url":"https://api.github.com/users/smlng/followers","following_url":"https://api.github.com/users/smlng/following{/other_user}","gists_url":"https://api.github.com/users/smlng/gists{/gist_id}","starred_url":"https://api.github.com/users/smlng/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/smlng/subscriptions","organizations_url":"https://api.github.com/users/smlng/orgs","repos_url":"https://api.github.com/users/smlng/repos","events_url":"https://api.github.com/users/smlng/events{/privacy}","received_events_url":"https://api.github.com/users/smlng/received_events","type":"User","site_admin":false},"body":"oh, I see its copy paste from before and my suggestion would be an API change ... mhm","created_at":"2018-05-24T10:08:11Z","updated_at":"2018-05-24T10:08:18Z","html_url":"https://github.com/RIOT-OS/RIOT/pull/9086#discussion_r190532960","pull_request_url":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/9086","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/comments/190532960"},"html":{"href":"https://github.com/RIOT-OS/RIOT/pull/9086#discussion_r190532960"},"pull_request":{"href":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/9086"}},"in_reply_to_id":190532671},"pull_request":{"url":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/9086","id":186203937,"html_url":"https://github.com/RIOT-OS/RIOT/pull/9086","diff_url":"https://github.com/RIOT-OS/RIOT/pull/9086.diff","patch_url":"https://github.com/RIOT-OS/RIOT/pull/9086.patch","issue_url":"https://api.github.com/repos/RIOT-OS/RIOT/issues/9086","number":9086,"state":"open","locked":false,"title":"nanocoap_sock: split generic request function of from nanocoap_get","user":{"login":"bergzand","id":5160052,"avatar_url":"https://avatars2.githubusercontent.com/u/5160052?v=4","gravatar_id":"","url":"https://api.github.com/users/bergzand","html_url":"https://github.com/bergzand","followers_url":"https://api.github.com/users/bergzand/followers","following_url":"https://api.github.com/users/bergzand/following{/other_user}","gists_url":"https://api.github.com/users/bergzand/gists{/gist_id}","starred_url":"https://api.github.com/users/bergzand/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bergzand/subscriptions","organizations_url":"https://api.github.com/users/bergzand/orgs","repos_url":"https://api.github.com/users/bergzand/repos","events_url":"https://api.github.com/users/bergzand/events{/privacy}","received_events_url":"https://api.github.com/users/bergzand/received_events","type":"User","site_admin":false},"body":"### Contribution description\r\n\r\nThe nanocoap_get function is refactored to split of the request part\r\ninto a separate function for reuse by other modules. Support for\r\nretransmissions when the received frame is malformed is dropped as it\r\nwas broken anyway.\r\n\r\n### Issues/PRs references\r\n\r\nNone","created_at":"2018-05-06T12:46:08Z","updated_at":"2018-05-24T10:08:18Z","closed_at":null,"merged_at":null,"merge_commit_sha":"e3e44352962960444810602ccb0da4a5f645bba5","assignee":null,"assignees":[],"requested_reviewers":[{"login":"kaspar030","id":4679640,"avatar_url":"https://avatars0.githubusercontent.com/u/4679640?v=4","gravatar_id":"","url":"https://api.github.com/users/kaspar030","html_url":"https://github.com/kaspar030","followers_url":"https://api.github.com/users/kaspar030/followers","following_url":"https://api.github.com/users/kaspar030/following{/other_user}","gists_url":"https://api.github.com/users/kaspar030/gists{/gist_id}","starred_url":"https://api.github.com/users/kaspar030/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kaspar030/subscriptions","organizations_url":"https://api.github.com/users/kaspar030/orgs","repos_url":"https://api.github.com/users/kaspar030/repos","events_url":"https://api.github.com/users/kaspar030/events{/privacy}","received_events_url":"https://api.github.com/users/kaspar030/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[{"id":23399100,"url":"https://api.github.com/repos/RIOT-OS/RIOT/labels/enhancement","name":"enhancement","color":"f17070","default":true},{"id":86443543,"url":"https://api.github.com/repos/RIOT-OS/RIOT/labels/network","name":"network","color":"8f00cc","default":false}],"milestone":null,"commits_url":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/9086/commits","review_comments_url":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/9086/comments","review_comment_url":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/comments{/number}","comments_url":"https://api.github.com/repos/RIOT-OS/RIOT/issues/9086/comments","statuses_url":"https://api.github.com/repos/RIOT-OS/RIOT/statuses/391c4fb67644135c045ab2a4ccb5d0ae25a758ec","head":{"label":"bergzand:pr/nanocoap_sock/client_split","ref":"pr/nanocoap_sock/client_split","sha":"391c4fb67644135c045ab2a4ccb5d0ae25a758ec","user":{"login":"bergzand","id":5160052,"avatar_url":"https://avatars2.githubusercontent.com/u/5160052?v=4","gravatar_id":"","url":"https://api.github.com/users/bergzand","html_url":"https://github.com/bergzand","followers_url":"https://api.github.com/users/bergzand/followers","following_url":"https://api.github.com/users/bergzand/following{/other_user}","gists_url":"https://api.github.com/users/bergzand/gists{/gist_id}","starred_url":"https://api.github.com/users/bergzand/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bergzand/subscriptions","organizations_url":"https://api.github.com/users/bergzand/orgs","repos_url":"https://api.github.com/users/bergzand/repos","events_url":"https://api.github.com/users/bergzand/events{/privacy}","received_events_url":"https://api.github.com/users/bergzand/received_events","type":"User","site_admin":false},"repo":{"id":73482253,"name":"RIOT","full_name":"bergzand/RIOT","owner":{"login":"bergzand","id":5160052,"avatar_url":"https://avatars2.githubusercontent.com/u/5160052?v=4","gravatar_id":"","url":"https://api.github.com/users/bergzand","html_url":"https://github.com/bergzand","followers_url":"https://api.github.com/users/bergzand/followers","following_url":"https://api.github.com/users/bergzand/following{/other_user}","gists_url":"https://api.github.com/users/bergzand/gists{/gist_id}","starred_url":"https://api.github.com/users/bergzand/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bergzand/subscriptions","organizations_url":"https://api.github.com/users/bergzand/orgs","repos_url":"https://api.github.com/users/bergzand/repos","events_url":"https://api.github.com/users/bergzand/events{/privacy}","received_events_url":"https://api.github.com/users/bergzand/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/bergzand/RIOT","description":"RIOT -  The friendly OS for IoT","fork":true,"url":"https://api.github.com/repos/bergzand/RIOT","forks_url":"https://api.github.com/repos/bergzand/RIOT/forks","keys_url":"https://api.github.com/repos/bergzand/RIOT/keys{/key_id}","collaborators_url":"https://api.github.com/repos/bergzand/RIOT/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/bergzand/RIOT/teams","hooks_url":"https://api.github.com/repos/bergzand/RIOT/hooks","issue_events_url":"https://api.github.com/repos/bergzand/RIOT/issues/events{/number}","events_url":"https://api.github.com/repos/bergzand/RIOT/events","assignees_url":"https://api.github.com/repos/bergzand/RIOT/assignees{/user}","branches_url":"https://api.github.com/repos/bergzand/RIOT/branches{/branch}","tags_url":"https://api.github.com/repos/bergzand/RIOT/tags","blobs_url":"https://api.github.com/repos/bergzand/RIOT/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/bergzand/RIOT/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/bergzand/RIOT/git/refs{/sha}","trees_url":"https://api.github.com/repos/bergzand/RIOT/git/trees{/sha}","statuses_url":"https://api.github.com/repos/bergzand/RIOT/statuses/{sha}","languages_url":"https://api.github.com/repos/bergzand/RIOT/languages","stargazers_url":"https://api.github.com/repos/bergzand/RIOT/stargazers","contributors_url":"https://api.github.com/repos/bergzand/RIOT/contributors","subscribers_url":"https://api.github.com/repos/bergzand/RIOT/subscribers","subscription_url":"https://api.github.com/repos/bergzand/RIOT/subscription","commits_url":"https://api.github.com/repos/bergzand/RIOT/commits{/sha}","git_commits_url":"https://api.github.com/repos/bergzand/RIOT/git/commits{/sha}","comments_url":"https://api.github.com/repos/bergzand/RIOT/comments{/number}","issue_comment_url":"https://api.github.com/repos/bergzand/RIOT/issues/comments{/number}","contents_url":"https://api.github.com/repos/bergzand/RIOT/contents/{+path}","compare_url":"https://api.github.com/repos/bergzand/RIOT/compare/{base}...{head}","merges_url":"https://api.github.com/repos/bergzand/RIOT/merges","archive_url":"https://api.github.com/repos/bergzand/RIOT/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/bergzand/RIOT/downloads","issues_url":"https://api.github.com/repos/bergzand/RIOT/issues{/number}","pulls_url":"https://api.github.com/repos/bergzand/RIOT/pulls{/number}","milestones_url":"https://api.github.com/repos/bergzand/RIOT/milestones{/number}","notifications_url":"https://api.github.com/repos/bergzand/RIOT/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/bergzand/RIOT/labels{/name}","releases_url":"https://api.github.com/repos/bergzand/RIOT/releases{/id}","deployments_url":"https://api.github.com/repos/bergzand/RIOT/deployments","created_at":"2016-11-11T14:02:28Z","updated_at":"2018-05-02T12:40:43Z","pushed_at":"2018-05-23T14:58:48Z","git_url":"git://github.com/bergzand/RIOT.git","ssh_url":"git@github.com:bergzand/RIOT.git","clone_url":"https://github.com/bergzand/RIOT.git","svn_url":"https://github.com/bergzand/RIOT","homepage":"https://github.com/RIOT-OS/RIOT/wiki","size":52989,"stargazers_count":0,"watchers_count":0,"language":"C","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"lgpl-2.1","name":"GNU Lesser General Public License v2.1","spdx_id":"LGPL-2.1","url":"https://api.github.com/licenses/lgpl-2.1"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"RIOT-OS:master","ref":"master","sha":"9020767c2dbe1a6e0e8d7914cc110eb680397cd6","user":{"login":"RIOT-OS","id":3079480,"avatar_url":"https://avatars2.githubusercontent.com/u/3079480?v=4","gravatar_id":"","url":"https://api.github.com/users/RIOT-OS","html_url":"https://github.com/RIOT-OS","followers_url":"https://api.github.com/users/RIOT-OS/followers","following_url":"https://api.github.com/users/RIOT-OS/following{/other_user}","gists_url":"https://api.github.com/users/RIOT-OS/gists{/gist_id}","starred_url":"https://api.github.com/users/RIOT-OS/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RIOT-OS/subscriptions","organizations_url":"https://api.github.com/users/RIOT-OS/orgs","repos_url":"https://api.github.com/users/RIOT-OS/repos","events_url":"https://api.github.com/users/RIOT-OS/events{/privacy}","received_events_url":"https://api.github.com/users/RIOT-OS/received_events","type":"Organization","site_admin":false},"repo":{"id":7370241,"name":"RIOT","full_name":"RIOT-OS/RIOT","owner":{"login":"RIOT-OS","id":3079480,"avatar_url":"https://avatars2.githubusercontent.com/u/3079480?v=4","gravatar_id":"","url":"https://api.github.com/users/RIOT-OS","html_url":"https://github.com/RIOT-OS","followers_url":"https://api.github.com/users/RIOT-OS/followers","following_url":"https://api.github.com/users/RIOT-OS/following{/other_user}","gists_url":"https://api.github.com/users/RIOT-OS/gists{/gist_id}","starred_url":"https://api.github.com/users/RIOT-OS/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/RIOT-OS/subscriptions","organizations_url":"https://api.github.com/users/RIOT-OS/orgs","repos_url":"https://api.github.com/users/RIOT-OS/repos","events_url":"https://api.github.com/users/RIOT-OS/events{/privacy}","received_events_url":"https://api.github.com/users/RIOT-OS/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/RIOT-OS/RIOT","description":"RIOT -  The friendly OS for IoT","fork":false,"url":"https://api.github.com/repos/RIOT-OS/RIOT","forks_url":"https://api.github.com/repos/RIOT-OS/RIOT/forks","keys_url":"https://api.github.com/repos/RIOT-OS/RIOT/keys{/key_id}","collaborators_url":"https://api.github.com/repos/RIOT-OS/RIOT/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/RIOT-OS/RIOT/teams","hooks_url":"https://api.github.com/repos/RIOT-OS/RIOT/hooks","issue_events_url":"https://api.github.com/repos/RIOT-OS/RIOT/issues/events{/number}","events_url":"https://api.github.com/repos/RIOT-OS/RIOT/events","assignees_url":"https://api.github.com/repos/RIOT-OS/RIOT/assignees{/user}","branches_url":"https://api.github.com/repos/RIOT-OS/RIOT/branches{/branch}","tags_url":"https://api.github.com/repos/RIOT-OS/RIOT/tags","blobs_url":"https://api.github.com/repos/RIOT-OS/RIOT/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/RIOT-OS/RIOT/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/RIOT-OS/RIOT/git/refs{/sha}","trees_url":"https://api.github.com/repos/RIOT-OS/RIOT/git/trees{/sha}","statuses_url":"https://api.github.com/repos/RIOT-OS/RIOT/statuses/{sha}","languages_url":"https://api.github.com/repos/RIOT-OS/RIOT/languages","stargazers_url":"https://api.github.com/repos/RIOT-OS/RIOT/stargazers","contributors_url":"https://api.github.com/repos/RIOT-OS/RIOT/contributors","subscribers_url":"https://api.github.com/repos/RIOT-OS/RIOT/subscribers","subscription_url":"https://api.github.com/repos/RIOT-OS/RIOT/subscription","commits_url":"https://api.github.com/repos/RIOT-OS/RIOT/commits{/sha}","git_commits_url":"https://api.github.com/repos/RIOT-OS/RIOT/git/commits{/sha}","comments_url":"https://api.github.com/repos/RIOT-OS/RIOT/comments{/number}","issue_comment_url":"https://api.github.com/repos/RIOT-OS/RIOT/issues/comments{/number}","contents_url":"https://api.github.com/repos/RIOT-OS/RIOT/contents/{+path}","compare_url":"https://api.github.com/repos/RIOT-OS/RIOT/compare/{base}...{head}","merges_url":"https://api.github.com/repos/RIOT-OS/RIOT/merges","archive_url":"https://api.github.com/repos/RIOT-OS/RIOT/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/RIOT-OS/RIOT/downloads","issues_url":"https://api.github.com/repos/RIOT-OS/RIOT/issues{/number}","pulls_url":"https://api.github.com/repos/RIOT-OS/RIOT/pulls{/number}","milestones_url":"https://api.github.com/repos/RIOT-OS/RIOT/milestones{/number}","notifications_url":"https://api.github.com/repos/RIOT-OS/RIOT/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/RIOT-OS/RIOT/labels{/name}","releases_url":"https://api.github.com/repos/RIOT-OS/RIOT/releases{/id}","deployments_url":"https://api.github.com/repos/RIOT-OS/RIOT/deployments","created_at":"2012-12-29T20:38:40Z","updated_at":"2018-05-24T09:56:22Z","pushed_at":"2018-05-24T10:06:48Z","git_url":"git://github.com/RIOT-OS/RIOT.git","ssh_url":"git@github.com:RIOT-OS/RIOT.git","clone_url":"https://github.com/RIOT-OS/RIOT.git","svn_url":"https://github.com/RIOT-OS/RIOT","homepage":"https://github.com/RIOT-OS/RIOT/wiki","size":52092,"stargazers_count":1794,"watchers_count":1794,"language":"C","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1067,"mirror_url":null,"archived":false,"open_issues_count":757,"license":{"key":"lgpl-2.1","name":"GNU Lesser General Public License v2.1","spdx_id":"LGPL-2.1","url":"https://api.github.com/licenses/lgpl-2.1"},"forks":1067,"open_issues":757,"watchers":1794,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/9086"},"html":{"href":"https://github.com/RIOT-OS/RIOT/pull/9086"},"issue":{"href":"https://api.github.com/repos/RIOT-OS/RIOT/issues/9086"},"comments":{"href":"https://api.github.com/repos/RIOT-OS/RIOT/issues/9086/comments"},"review_comments":{"href":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/9086/comments"},"review_comment":{"href":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/RIOT-OS/RIOT/pulls/9086/commits"},"statuses":{"href":"https://api.github.com/repos/RIOT-OS/RIOT/statuses/391c4fb67644135c045ab2a4ccb5d0ae25a758ec"}},"author_association":"MEMBER"}}
{"actor":{"display_login":"smlng"}}