This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: RFA: New port: ia64-hp-openvms (3/3) - ia64-vms-tdep.c


On 02/15/2012 08:05 AM, Tristan Gingold wrote:
> 
> On Feb 14, 2012, at 6:50 PM, Pedro Alves wrote:

>>> +  info_len = extract_unsigned_integer (buf + 0, 4, byte_order);
>>> +  pi->unwind_info_size = 8 * info_len;
>>> +
>>> +  /* Read info.  */
>>> +  pi->unwind_info = malloc (pi->unwind_info_size);
>>
>> xmalloc
> 
> Humm, do we want to exit abruptly in case of memory error ?  Note that we test the return status.

Ah, missed that.  Fine with me to stay with malloc.  What does
libunwind do when one returns -UNW_ENOMEM?  Does GDB end up recovering correctly,
or do we end up busted anyway?

> (OTOH, if malloc fails here, it is likely that the next xmalloc will too).

Right...

-- 
Pedro Alves


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]