diff options
| author | Rashmica Gupta <rashmica.g@gmail.com> | 2018-05-15 13:42:07 +1000 |
|---|---|---|
| committer | Alistair Popple <alistair@popple.id.au> | 2018-05-17 16:01:58 +1000 |
| commit | c9e116fda27482618b859e8375691f70bac0f293 (patch) | |
| tree | 70e2f62e0e539d211e30e63bd23f2619897fa4b4 /src | |
| parent | c4abce3af2bd041f45732c9fd2a807bf045dbbca (diff) | |
| download | pdbg-c9e116fda27482618b859e8375691f70bac0f293.tar.gz pdbg-c9e116fda27482618b859e8375691f70bac0f293.zip | |
libpdbg: Add missing lazy probe in putmem
Without this patch, attempting to write to memory causes a segfault.
Signed-off-by: Rashmica Gupta <rashmica.g@gmail.com>
Diffstat (limited to 'src')
| -rw-r--r-- | src/mem.c | 3 |
1 files changed, 3 insertions, 0 deletions
@@ -60,6 +60,9 @@ static int putmem(uint64_t addr) pdbg_for_each_class_target("adu", adu_target) break; + if (pdbg_target_probe(adu_target) != PDBG_TARGET_ENABLED) + return 0; + buf = malloc(PUTMEM_BUF_SIZE); assert(buf); do { |

