projects
/
deliverable
/
binutils-gdb.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Change `function_symbols' to std::vector
[deliverable/binutils-gdb.git]
/
opcodes
/
dis-buf.c
diff --git
a/opcodes/dis-buf.c
b/opcodes/dis-buf.c
index cc0e3ad2fba99c187f6388fc01f74361961bfb7c..e4911b9ecda77f51576705375e7fcacb93c7ab2a 100644
(file)
--- a/
opcodes/dis-buf.c
+++ b/
opcodes/dis-buf.c
@@
-1,5
+1,5
@@
/* Disassemble from a buffer, for GNU.
/* Disassemble from a buffer, for GNU.
- Copyright (C) 1993-201
5
Free Software Foundation, Inc.
+ Copyright (C) 1993-201
8
Free Software Foundation, Inc.
This file is part of the GNU opcodes library.
This file is part of the GNU opcodes library.
@@
-32,13
+32,15
@@
buffer_read_memory (bfd_vma memaddr,
struct disassemble_info *info)
{
unsigned int opb = info->octets_per_byte;
struct disassemble_info *info)
{
unsigned int opb = info->octets_per_byte;
-
unsigned in
t end_addr_offset = length / opb;
- unsigned int max_addr_offset = info->buffer_length / opb;
-
unsigned in
t octets = (memaddr - info->buffer_vma) * opb;
+
size_
t end_addr_offset = length / opb;
+ size_t max_addr_offset = info->buffer_length / opb;
+
size_
t octets = (memaddr - info->buffer_vma) * opb;
if (memaddr < info->buffer_vma
|| memaddr - info->buffer_vma > max_addr_offset
if (memaddr < info->buffer_vma
|| memaddr - info->buffer_vma > max_addr_offset
- || memaddr - info->buffer_vma + end_addr_offset > max_addr_offset)
+ || memaddr - info->buffer_vma + end_addr_offset > max_addr_offset
+ || (info->stop_vma && (memaddr >= info->stop_vma
+ || memaddr + end_addr_offset > info->stop_vma)))
/* Out of bounds. Use EIO because GDB uses it. */
return EIO;
memcpy (myaddr, info->buffer + octets, length);
/* Out of bounds. Use EIO because GDB uses it. */
return EIO;
memcpy (myaddr, info->buffer + octets, length);
This page took
0.023311 seconds
and
4
git commands to generate.