]> git.sur5r.net Git - openocd/commitdiff
dump_image now works for addresses not divisible by 4
authoroharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60>
Thu, 14 May 2009 18:56:41 +0000 (18:56 +0000)
committeroharboe <oharboe@b42882b7-edfa-0310-969c-e2dbd0fdcd60>
Thu, 14 May 2009 18:56:41 +0000 (18:56 +0000)
git-svn-id: svn://svn.berlios.de/openocd/trunk@1785 b42882b7-edfa-0310-969c-e2dbd0fdcd60

src/target/target.c

index a0cbf85c57cef729134eef0f75736d2575ec8d95..c1031a024ad9f962c501c0829944ec742c1190e4 100644 (file)
@@ -2133,7 +2133,7 @@ static int handle_dump_image_command(struct command_context_s *cmd_ctx, char *cm
                u32 size_written;
                u32 this_run_size = (size > 560) ? 560 : size;
 
-               retval = target->type->read_memory(target, address, 4, this_run_size / 4, buffer);
+               retval = target_read_buffer(target, address, this_run_size, buffer);
                if (retval != ERROR_OK)
                {
                        break;