def _get_ascii_string(self, address, min_length=4, max_length=32):
            """
            Get the ASCII string of length at least `min_length`, but
             not more than `max_length` of it, or raise
             `NotAStringError` if it doesnt look like an ASCII string.
            """
            cs = []
            for i in xrange(max_length):
                try:
                    c = self.memory(address + i, 1)[0]
                except FailedToReadMemoryError:
                    break
                if ord(c) == 0:
                    break
                elif c not in string.printable:
                    break
                else:
                    cs.append(c)

            if len(cs) >= min_length:
                return "".join(cs)
            else:
                raise NotAStringError()
dataset/ETHPy150Open snare/voltron/voltron/plugins/debugger/dbg_vdb.py/VDBAdaptor._get_ascii_string/original