void
start_msglist(void)
{
- struct selname *newobj =
- (struct selname *) xmalloc (sizeof (struct selname));
+ struct selname *newobj = XNEW (struct selname);
newobj->next = selname_chain;
newobj->msglist_len = msglist_len;
printf_filtered (_("Selectors matching \"%s\":\n\n"),
regexp ? regexp : "*");
- sym_arr = alloca (matches * sizeof (struct symbol *));
+ sym_arr = XALLOCAVEC (struct symbol *, matches);
matches = 0;
ALL_MSYMBOLS (objfile, msymbol)
{
{
printf_filtered (_("Classes matching \"%s\":\n\n"),
regexp ? regexp : "*");
- sym_arr = alloca (matches * sizeof (struct symbol *));
+ sym_arr = XALLOCAVEC (struct symbol *, matches);
matches = 0;
ALL_MSYMBOLS (objfile, msymbol)
{
if (objc_csym == NULL)
{
- objc_csym = obstack_alloc (&objfile->objfile_obstack,
- sizeof (*objc_csym));
+ objc_csym = XOBNEW (&objfile->objfile_obstack, unsigned int);
*objc_csym = objfile_csym;
set_objfile_data (objfile, objc_objfile_data, objc_csym);
}