{"action":"created","comment":{"url":"https://api.github.com/repos/vbatts/go-mtree/pulls/comments/71642841","id":71642841,"diff_hunk":"@@ -4,10 +4,13 @@ package mtree\n import \"C\"\n import \"fmt\"\n \n+// Vis is a wrapper of the C implementation of the function vis, which encodes\n+// a character with a particular format/style\n func Vis(str string) (string, error) {\n-\tdst := new(C.char)\n+\t// dst needs to be 4 times the length of str (plus 1 for null char)\n+\tdst := C.CString(string(make([]byte, 4*len(str)+1)))\n \tret := C.strvis(dst, C.CString(str), C.VIS_WHITE|C.VIS_OCTAL|C.VIS_GLOB)\n-\tif ret == 0 {","path":"vis.go","position":11,"original_position":11,"commit_id":"2062c5a542c24d1f758db41e5db9ff7907398324","original_commit_id":"2062c5a542c24d1f758db41e5db9ff7907398324","user":{"login":"vbatts","id":67049,"avatar_url":"https://avatars.githubusercontent.com/u/67049?v=3","gravatar_id":"","url":"https://api.github.com/users/vbatts","html_url":"https://github.com/vbatts","followers_url":"https://api.github.com/users/vbatts/followers","following_url":"https://api.github.com/users/vbatts/following{/other_user}","gists_url":"https://api.github.com/users/vbatts/gists{/gist_id}","starred_url":"https://api.github.com/users/vbatts/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vbatts/subscriptions","organizations_url":"https://api.github.com/users/vbatts/orgs","repos_url":"https://api.github.com/users/vbatts/repos","events_url":"https://api.github.com/users/vbatts/events{/privacy}","received_events_url":"https://api.github.com/users/vbatts/received_events","type":"User","site_admin":false},"body":"Oh nice. Dropping the error will trim up several things then.\n\nOn Wed, Jul 20, 2016, 23:29 Stephen Chung <notifications@github.com> wrote:\n\n> In vis.go\n> <https://github.com/vbatts/go-mtree/pull/32#discussion_r71642570>:\n>\n> >  \tret := C.strvis(dst, C.CString(str), C.VIS_WHITE|C.VIS_OCTAL|C.VIS_GLOB)\n> > -\tif ret == 0 {\n>\n> the functions that I have are:\n>\n> Encode (str string) string and Decode (str string) string\n>\n> —\n> You are receiving this because you commented.\n> Reply to this email directly, view it on GitHub\n> <https://github.com/vbatts/go-mtree/pull/32/files/2062c5a542c24d1f758db41e5db9ff7907398324#r71642570>,\n> or mute the thread\n> <https://github.com/notifications/unsubscribe-auth/AAEF6aSQoZ0jJPWolFL3fa7Qm7tZzyFNks5qXueCgaJpZM4JRXDl>\n> .\n>\n","created_at":"2016-07-21T03:34:10Z","updated_at":"2016-07-21T03:34:10Z","html_url":"https://github.com/vbatts/go-mtree/pull/32#discussion_r71642841","pull_request_url":"https://api.github.com/repos/vbatts/go-mtree/pulls/32","_links":{"self":{"href":"https://api.github.com/repos/vbatts/go-mtree/pulls/comments/71642841"},"html":{"href":"https://github.com/vbatts/go-mtree/pull/32#discussion_r71642841"},"pull_request":{"href":"https://api.github.com/repos/vbatts/go-mtree/pulls/32"}}},"pull_request":{"url":"https://api.github.com/repos/vbatts/go-mtree/pulls/32","id":78245045,"html_url":"https://github.com/vbatts/go-mtree/pull/32","diff_url":"https://github.com/vbatts/go-mtree/pull/32.diff","patch_url":"https://github.com/vbatts/go-mtree/pull/32.patch","issue_url":"https://api.github.com/repos/vbatts/go-mtree/issues/32","number":32,"state":"open","locked":false,"title":"vis: refactored code to reflect using vis() to represent file names","user":{"login":"stephen679","id":9023630,"avatar_url":"https://avatars.githubusercontent.com/u/9023630?v=3","gravatar_id":"","url":"https://api.github.com/users/stephen679","html_url":"https://github.com/stephen679","followers_url":"https://api.github.com/users/stephen679/followers","following_url":"https://api.github.com/users/stephen679/following{/other_user}","gists_url":"https://api.github.com/users/stephen679/gists{/gist_id}","starred_url":"https://api.github.com/users/stephen679/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stephen679/subscriptions","organizations_url":"https://api.github.com/users/stephen679/orgs","repos_url":"https://api.github.com/users/stephen679/repos","events_url":"https://api.github.com/users/stephen679/events{/privacy}","received_events_url":"https://api.github.com/users/stephen679/received_events","type":"User","site_admin":false},"body":"Refactored gomtree with the `vis` and `unvis` C functions. Validation manifest should now be in same format with upstream mtree in terms of how filenames are represented.\r\n\r\nSigned-off-by: Stephen Chung <schung@redhat.com>","created_at":"2016-07-21T01:25:10Z","updated_at":"2016-07-21T03:34:10Z","closed_at":null,"merged_at":null,"merge_commit_sha":"20a2b89161e7d1277ae51402fb9ecfa9a8c224fc","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/vbatts/go-mtree/pulls/32/commits","review_comments_url":"https://api.github.com/repos/vbatts/go-mtree/pulls/32/comments","review_comment_url":"https://api.github.com/repos/vbatts/go-mtree/pulls/comments{/number}","comments_url":"https://api.github.com/repos/vbatts/go-mtree/issues/32/comments","statuses_url":"https://api.github.com/repos/vbatts/go-mtree/statuses/2062c5a542c24d1f758db41e5db9ff7907398324","head":{"label":"stephen679:vis","ref":"vis","sha":"2062c5a542c24d1f758db41e5db9ff7907398324","user":{"login":"stephen679","id":9023630,"avatar_url":"https://avatars.githubusercontent.com/u/9023630?v=3","gravatar_id":"","url":"https://api.github.com/users/stephen679","html_url":"https://github.com/stephen679","followers_url":"https://api.github.com/users/stephen679/followers","following_url":"https://api.github.com/users/stephen679/following{/other_user}","gists_url":"https://api.github.com/users/stephen679/gists{/gist_id}","starred_url":"https://api.github.com/users/stephen679/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stephen679/subscriptions","organizations_url":"https://api.github.com/users/stephen679/orgs","repos_url":"https://api.github.com/users/stephen679/repos","events_url":"https://api.github.com/users/stephen679/events{/privacy}","received_events_url":"https://api.github.com/users/stephen679/received_events","type":"User","site_admin":false},"repo":{"id":61751188,"name":"go-mtree","full_name":"stephen679/go-mtree","owner":{"login":"stephen679","id":9023630,"avatar_url":"https://avatars.githubusercontent.com/u/9023630?v=3","gravatar_id":"","url":"https://api.github.com/users/stephen679","html_url":"https://github.com/stephen679","followers_url":"https://api.github.com/users/stephen679/followers","following_url":"https://api.github.com/users/stephen679/following{/other_user}","gists_url":"https://api.github.com/users/stephen679/gists{/gist_id}","starred_url":"https://api.github.com/users/stephen679/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stephen679/subscriptions","organizations_url":"https://api.github.com/users/stephen679/orgs","repos_url":"https://api.github.com/users/stephen679/repos","events_url":"https://api.github.com/users/stephen679/events{/privacy}","received_events_url":"https://api.github.com/users/stephen679/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/stephen679/go-mtree","description":"golang library and cli support for mtree(8)","fork":true,"url":"https://api.github.com/repos/stephen679/go-mtree","forks_url":"https://api.github.com/repos/stephen679/go-mtree/forks","keys_url":"https://api.github.com/repos/stephen679/go-mtree/keys{/key_id}","collaborators_url":"https://api.github.com/repos/stephen679/go-mtree/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/stephen679/go-mtree/teams","hooks_url":"https://api.github.com/repos/stephen679/go-mtree/hooks","issue_events_url":"https://api.github.com/repos/stephen679/go-mtree/issues/events{/number}","events_url":"https://api.github.com/repos/stephen679/go-mtree/events","assignees_url":"https://api.github.com/repos/stephen679/go-mtree/assignees{/user}","branches_url":"https://api.github.com/repos/stephen679/go-mtree/branches{/branch}","tags_url":"https://api.github.com/repos/stephen679/go-mtree/tags","blobs_url":"https://api.github.com/repos/stephen679/go-mtree/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/stephen679/go-mtree/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/stephen679/go-mtree/git/refs{/sha}","trees_url":"https://api.github.com/repos/stephen679/go-mtree/git/trees{/sha}","statuses_url":"https://api.github.com/repos/stephen679/go-mtree/statuses/{sha}","languages_url":"https://api.github.com/repos/stephen679/go-mtree/languages","stargazers_url":"https://api.github.com/repos/stephen679/go-mtree/stargazers","contributors_url":"https://api.github.com/repos/stephen679/go-mtree/contributors","subscribers_url":"https://api.github.com/repos/stephen679/go-mtree/subscribers","subscription_url":"https://api.github.com/repos/stephen679/go-mtree/subscription","commits_url":"https://api.github.com/repos/stephen679/go-mtree/commits{/sha}","git_commits_url":"https://api.github.com/repos/stephen679/go-mtree/git/commits{/sha}","comments_url":"https://api.github.com/repos/stephen679/go-mtree/comments{/number}","issue_comment_url":"https://api.github.com/repos/stephen679/go-mtree/issues/comments{/number}","contents_url":"https://api.github.com/repos/stephen679/go-mtree/contents/{+path}","compare_url":"https://api.github.com/repos/stephen679/go-mtree/compare/{base}...{head}","merges_url":"https://api.github.com/repos/stephen679/go-mtree/merges","archive_url":"https://api.github.com/repos/stephen679/go-mtree/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/stephen679/go-mtree/downloads","issues_url":"https://api.github.com/repos/stephen679/go-mtree/issues{/number}","pulls_url":"https://api.github.com/repos/stephen679/go-mtree/pulls{/number}","milestones_url":"https://api.github.com/repos/stephen679/go-mtree/milestones{/number}","notifications_url":"https://api.github.com/repos/stephen679/go-mtree/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/stephen679/go-mtree/labels{/name}","releases_url":"https://api.github.com/repos/stephen679/go-mtree/releases{/id}","deployments_url":"https://api.github.com/repos/stephen679/go-mtree/deployments","created_at":"2016-06-22T21:00:16Z","updated_at":"2016-06-30T20:32:47Z","pushed_at":"2016-07-21T01:21:27Z","git_url":"git://github.com/stephen679/go-mtree.git","ssh_url":"git@github.com:stephen679/go-mtree.git","clone_url":"https://github.com/stephen679/go-mtree.git","svn_url":"https://github.com/stephen679/go-mtree","homepage":null,"size":281,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":5,"forks":0,"open_issues":5,"watchers":0,"default_branch":"master"}},"base":{"label":"vbatts:vis","ref":"vis","sha":"9bec5e46b7c2dacca4c202289dec11779c376c16","user":{"login":"vbatts","id":67049,"avatar_url":"https://avatars.githubusercontent.com/u/67049?v=3","gravatar_id":"","url":"https://api.github.com/users/vbatts","html_url":"https://github.com/vbatts","followers_url":"https://api.github.com/users/vbatts/followers","following_url":"https://api.github.com/users/vbatts/following{/other_user}","gists_url":"https://api.github.com/users/vbatts/gists{/gist_id}","starred_url":"https://api.github.com/users/vbatts/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vbatts/subscriptions","organizations_url":"https://api.github.com/users/vbatts/orgs","repos_url":"https://api.github.com/users/vbatts/repos","events_url":"https://api.github.com/users/vbatts/events{/privacy}","received_events_url":"https://api.github.com/users/vbatts/received_events","type":"User","site_admin":false},"repo":{"id":54672347,"name":"go-mtree","full_name":"vbatts/go-mtree","owner":{"login":"vbatts","id":67049,"avatar_url":"https://avatars.githubusercontent.com/u/67049?v=3","gravatar_id":"","url":"https://api.github.com/users/vbatts","html_url":"https://github.com/vbatts","followers_url":"https://api.github.com/users/vbatts/followers","following_url":"https://api.github.com/users/vbatts/following{/other_user}","gists_url":"https://api.github.com/users/vbatts/gists{/gist_id}","starred_url":"https://api.github.com/users/vbatts/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vbatts/subscriptions","organizations_url":"https://api.github.com/users/vbatts/orgs","repos_url":"https://api.github.com/users/vbatts/repos","events_url":"https://api.github.com/users/vbatts/events{/privacy}","received_events_url":"https://api.github.com/users/vbatts/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/vbatts/go-mtree","description":"golang library and cli support for mtree(8)","fork":false,"url":"https://api.github.com/repos/vbatts/go-mtree","forks_url":"https://api.github.com/repos/vbatts/go-mtree/forks","keys_url":"https://api.github.com/repos/vbatts/go-mtree/keys{/key_id}","collaborators_url":"https://api.github.com/repos/vbatts/go-mtree/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/vbatts/go-mtree/teams","hooks_url":"https://api.github.com/repos/vbatts/go-mtree/hooks","issue_events_url":"https://api.github.com/repos/vbatts/go-mtree/issues/events{/number}","events_url":"https://api.github.com/repos/vbatts/go-mtree/events","assignees_url":"https://api.github.com/repos/vbatts/go-mtree/assignees{/user}","branches_url":"https://api.github.com/repos/vbatts/go-mtree/branches{/branch}","tags_url":"https://api.github.com/repos/vbatts/go-mtree/tags","blobs_url":"https://api.github.com/repos/vbatts/go-mtree/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/vbatts/go-mtree/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/vbatts/go-mtree/git/refs{/sha}","trees_url":"https://api.github.com/repos/vbatts/go-mtree/git/trees{/sha}","statuses_url":"https://api.github.com/repos/vbatts/go-mtree/statuses/{sha}","languages_url":"https://api.github.com/repos/vbatts/go-mtree/languages","stargazers_url":"https://api.github.com/repos/vbatts/go-mtree/stargazers","contributors_url":"https://api.github.com/repos/vbatts/go-mtree/contributors","subscribers_url":"https://api.github.com/repos/vbatts/go-mtree/subscribers","subscription_url":"https://api.github.com/repos/vbatts/go-mtree/subscription","commits_url":"https://api.github.com/repos/vbatts/go-mtree/commits{/sha}","git_commits_url":"https://api.github.com/repos/vbatts/go-mtree/git/commits{/sha}","comments_url":"https://api.github.com/repos/vbatts/go-mtree/comments{/number}","issue_comment_url":"https://api.github.com/repos/vbatts/go-mtree/issues/comments{/number}","contents_url":"https://api.github.com/repos/vbatts/go-mtree/contents/{+path}","compare_url":"https://api.github.com/repos/vbatts/go-mtree/compare/{base}...{head}","merges_url":"https://api.github.com/repos/vbatts/go-mtree/merges","archive_url":"https://api.github.com/repos/vbatts/go-mtree/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/vbatts/go-mtree/downloads","issues_url":"https://api.github.com/repos/vbatts/go-mtree/issues{/number}","pulls_url":"https://api.github.com/repos/vbatts/go-mtree/pulls{/number}","milestones_url":"https://api.github.com/repos/vbatts/go-mtree/milestones{/number}","notifications_url":"https://api.github.com/repos/vbatts/go-mtree/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/vbatts/go-mtree/labels{/name}","releases_url":"https://api.github.com/repos/vbatts/go-mtree/releases{/id}","deployments_url":"https://api.github.com/repos/vbatts/go-mtree/deployments","created_at":"2016-03-24T20:32:59Z","updated_at":"2016-07-20T20:25:08Z","pushed_at":"2016-07-21T01:25:10Z","git_url":"git://github.com/vbatts/go-mtree.git","ssh_url":"git@github.com:vbatts/go-mtree.git","clone_url":"https://github.com/vbatts/go-mtree.git","svn_url":"https://github.com/vbatts/go-mtree","homepage":null,"size":251,"stargazers_count":7,"watchers_count":7,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":9,"forks":2,"open_issues":9,"watchers":7,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/vbatts/go-mtree/pulls/32"},"html":{"href":"https://github.com/vbatts/go-mtree/pull/32"},"issue":{"href":"https://api.github.com/repos/vbatts/go-mtree/issues/32"},"comments":{"href":"https://api.github.com/repos/vbatts/go-mtree/issues/32/comments"},"review_comments":{"href":"https://api.github.com/repos/vbatts/go-mtree/pulls/32/comments"},"review_comment":{"href":"https://api.github.com/repos/vbatts/go-mtree/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/vbatts/go-mtree/pulls/32/commits"},"statuses":{"href":"https://api.github.com/repos/vbatts/go-mtree/statuses/2062c5a542c24d1f758db41e5db9ff7907398324"}}}}
{"actor":{"display_login":"vbatts"}}