2005-12-08 Jan Beulich <jbeulich@novell.com>
* i386-dis.c (MAXLEN): Reduce to architectural limit.
(fetch_data): Check for sufficient buffer size.
2005-12-08 Jan Beulich <jbeulich@novell.com>
2005-12-08 Jan Beulich <jbeulich@novell.com>
+ * i386-dis.c (MAXLEN): Reduce to architectural limit.
+ (fetch_data): Check for sufficient buffer size.
+
+2005-12-08 Jan Beulich <jbeulich@novell.com>
+
* i386-dis.c (OP_ST): Remove prefix in Intel mode.
2005-12-08 Daniel Jacobowitz <dan@codesourcery.com>
* i386-dis.c (OP_ST): Remove prefix in Intel mode.
2005-12-08 Daniel Jacobowitz <dan@codesourcery.com>
#include "sysdep.h"
#include "opintl.h"
#include "sysdep.h"
#include "opintl.h"
struct dis_private *priv = (struct dis_private *) info->private_data;
bfd_vma start = priv->insn_start + (priv->max_fetched - priv->the_buffer);
struct dis_private *priv = (struct dis_private *) info->private_data;
bfd_vma start = priv->insn_start + (priv->max_fetched - priv->the_buffer);
- status = (*info->read_memory_func) (start,
- priv->max_fetched,
- addr - priv->max_fetched,
- info);
+ if (addr <= priv->the_buffer + MAXLEN)
+ status = (*info->read_memory_func) (start,
+ priv->max_fetched,
+ addr - priv->max_fetched,
+ info);
+ else
+ status = -1;
if (status != 0)
{
/* If we did manage to read at least one byte, then
if (status != 0)
{
/* If we did manage to read at least one byte, then