Skip to content

Commit

Permalink
add getters: file reader, file handler, memory segments
Browse files Browse the repository at this point in the history
  • Loading branch information
abcdywh committed Sep 8, 2021
1 parent 959b538 commit d8b6ccd
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions minidump/minidumpreader.py
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,9 @@ def _select_segment(self, requested_position):

raise Exception('Memory address 0x%08x is not in process memory space' % requested_position)

def get_reader(self):
return self.reader

def seek(self, offset, whence = 0):
"""
Changes the current address to an offset of offset. The whence parameter controls from which position should we count the offsets.
Expand Down Expand Up @@ -305,6 +308,12 @@ def __init__(self, minidumpfile):
else:
raise Exception('Unknown processor architecture %s! Please fix and submit PR!' % self.sysinfo.ProcessorArchitecture)

def get_handler(self):
return self.file_handle

def get_memory(self):
return self.memory_segments

def get_buffered_reader(self, segment_chunk_size = 10*1024):
return MinidumpBufferedReader(self, segment_chunk_size = segment_chunk_size)

Expand Down

0 comments on commit d8b6ccd

Please sign in to comment.