lokikiller / gopacket

Automatically exported from code.google.com/p/gopacket
BSD 3-Clause "New" or "Revised" License
0 stars 1 forks source link

pcap WritePacketData copies data unnecessarily #33

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
WritePacketData makes a copy of the data with C.CString(string(data)), which is 
expensive and wholly unnecessary.

Patch to fix that is on a branch at 
https://code.google.com/r/matthiasradestock-gopacket-pcap/source/list?name=pcap_
zero_copy_write_packet_data

Original issue reported on code.google.com by matthias...@gmail.com on 6 Aug 2014 at 11:31

GoogleCodeExporter commented 9 years ago
Committed in: 
https://code.google.com/p/gopacket/source/detail?r=b7f6fab1f7f56578407345ee0862d
3cb14cd750b

Original comment by gconnell@google.com on 6 Aug 2014 at 11:16