{"action":"opened","issue":{"url":"https://api.github.com/repos/google/gopacket/issues/219","repository_url":"https://api.github.com/repos/google/gopacket","labels_url":"https://api.github.com/repos/google/gopacket/issues/219/labels{/name}","comments_url":"https://api.github.com/repos/google/gopacket/issues/219/comments","events_url":"https://api.github.com/repos/google/gopacket/issues/219/events","html_url":"https://github.com/google/gopacket/issues/219","id":170293668,"number":219,"title":"pcapgo's ReadPacketData has ZeroCopyReadPacketData semantics","user":{"login":"mspielberg","id":9729801,"avatar_url":"https://avatars.githubusercontent.com/u/9729801?v=3","gravatar_id":"","url":"https://api.github.com/users/mspielberg","html_url":"https://github.com/mspielberg","followers_url":"https://api.github.com/users/mspielberg/followers","following_url":"https://api.github.com/users/mspielberg/following{/other_user}","gists_url":"https://api.github.com/users/mspielberg/gists{/gist_id}","starred_url":"https://api.github.com/users/mspielberg/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mspielberg/subscriptions","organizations_url":"https://api.github.com/users/mspielberg/orgs","repos_url":"https://api.github.com/users/mspielberg/repos","events_url":"https://api.github.com/users/mspielberg/events{/privacy}","received_events_url":"https://api.github.com/users/mspielberg/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-08-09T23:19:07Z","updated_at":"2016-08-09T23:19:07Z","closed_at":null,"body":"pcapgo allocates a single buffer while reading the file header of a pcap dump. Every call to ReadPacketData() overwrites this buffer, and returns a slice pointing into this buffer, so successive calls invalidate the slice returned from prior calls. This is unexpected, and makes pcapgo not a drop-in replacement for pcap.OpenOffline().\r\n\r\npcapgo should probably get a ReadPacketData() that populates a freshly allocated slice on each call, for compatibility, and the current method should be renamed ZeroCopyReadPacketData()."}}
{"actor":{"display_login":"mspielberg"}}