Beispiel #1
0
def string_at(p, length=None):
    if isinstance(p, c_void_p):
        p = Pointer(p.value)

    if length:
        return p.getByteArray(0, length).tostring()

    return p.getString(0).encode('utf-8')
Beispiel #2
0
 def __init__(self, value):
     self.value = Pointer(value)