MCPcopy Index your code
hub / github.com/secdev/scapy / h2i

Method h2i

scapy/fields.py:1489–1491  ·  view source on GitHub ↗
(self, pkt, x)

Source from the content-addressed store, hash-verified

1487 return plain_str(self.i2h(pkt, x))
1488
1489 def h2i(self, pkt, x):
1490 # type: (Optional[Packet], Optional[str]) -> bytes
1491 return plain_str(x).encode('utf-16-le', errors="replace")
1492
1493 def i2h(self, pkt, x):
1494 # type: (Optional[Packet], bytes) -> str

Callers 1

any2iMethod · 0.95

Calls 2

plain_strFunction · 0.90
encodeMethod · 0.80

Tested by

no test coverage detected