MCPcopy Index your code
hub / github.com/google/gopacket / byteSliceToString

Function byteSliceToString

pcap/pcap_windows.go:85–92  ·  view source on GitHub ↗
(bval []byte)

Source from the content-addressed store, hash-verified

83}
84
85func byteSliceToString(bval []byte) string {
86 for i := range bval {
87 if bval[i] == 0 {
88 return string(bval[:i])
89 }
90 }
91 return string(bval[:])
92}
93
94// bytePtrToString returns a string copied from pointer to a null terminated byte array
95// WARNING: ONLY SAFE WITH IF r POINTS TO C MEMORY!

Callers 7

bytePtrToStringFunction · 0.85
pcapOpenLiveFunction · 0.85
openOfflineFunction · 0.85
pcapLookupnetFunction · 0.85
pcapFindAllDevsFunction · 0.85
pcapCreateFunction · 0.85
openOfflineFileFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…