+2005-03-25 Anthony Green <green@redhat.com>
+
+ * remote.c (remote_store_registers): Fix memset usage.
+ * std-regs.c (value_of_builtin_frame_reg): Ditto.
+ (value_of_builtin_frame_fp_reg): Ditto.
+ (value_of_builtin_frame_reg): Ditto.
+
2005-03-25 Mark Mitchell <mark@codesourcery.com>
* ser-base.c (ser_unix_write): Rename to ...
{
int i;
regs = alloca (rs->sizeof_g_packet);
- memset (regs, rs->sizeof_g_packet, 0);
+ memset (regs, 0, rs->sizeof_g_packet);
for (i = 0; i < NUM_REGS + NUM_PSEUDO_REGS; i++)
{
struct packet_reg *r = &rs->regs[i];
val = allocate_value (builtin_type_frame_reg);
VALUE_LVAL (val) = not_lval;
buf = value_contents_raw (val);
- memset (buf, TYPE_LENGTH (value_type (val)), 0);
+ memset (buf, 0, TYPE_LENGTH (value_type (val)));
/* frame.base. */
if (frame != NULL)
ADDRESS_TO_POINTER (builtin_type_void_data_ptr, buf,
struct value *val = allocate_value (builtin_type_void_data_ptr);
char *buf = value_contents_raw (val);
if (frame == NULL)
- memset (buf, TYPE_LENGTH (value_type (val)), 0);
+ memset (buf, 0, TYPE_LENGTH (value_type (val)));
else
ADDRESS_TO_POINTER (builtin_type_void_data_ptr, buf,
get_frame_base_address (frame));
struct value *val = allocate_value (builtin_type_void_data_ptr);
char *buf = value_contents_raw (val);
if (frame == NULL)
- memset (buf, TYPE_LENGTH (value_type (val)), 0);
+ memset (buf, 0, TYPE_LENGTH (value_type (val)));
else
ADDRESS_TO_POINTER (builtin_type_void_data_ptr, buf,
get_frame_pc (frame));
if (device_nr_size_cells(bus) > 0)
chp = parse_size(current, bus, chp, ®s[reg_nr].size);
else
- memset(®s[reg_nr].size, sizeof (®s[reg_nr].size), 0);
+ memset(®s[reg_nr].size, 0, sizeof (®s[reg_nr].size));
}
/* create it */