MCPcopy Create free account
hub / github.com/qilingframework/qiling / __read_string

Method __read_string

qiling/os/memory.py:92–101  ·  view source on GitHub ↗
(self, addr: int)

Source from the content-addressed store, hash-verified

90
91
92 def __read_string(self, addr: int) -> str:
93 ret = bytearray()
94 c = self.read(addr, 1)
95
96 while c[0]:
97 ret += c
98 addr += 1
99 c = self.read(addr, 1)
100
101 return ret.decode('latin1')
102
103 def __write_string(self, addr: int, s: str, encoding: str):
104 self.write(addr, bytes(s, encoding) + b'\x00')

Callers 1

stringMethod · 0.95

Calls 1

readMethod · 0.95

Tested by

no test coverage detected