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: Fix compile time warnings building iq2000-tdep.c


On Tue, Nov 28, 2006 at 04:43:46PM +0000, Nick Clifton wrote:
> Hi Guys,
> 
>   The iq2000 port of GDB currently fails to build on the 6.6 branch
>   and mainline because of compile time warnings triggered in
>   iq2000-tdep.c, (which are now being treated as errors).  The
>   patch below fixes them by changing various void* variables into
>   gdb_byte*.
> 
>   May I apply the patch please ? 

Looks OK except...

> *************** iq2000_extract_return_value (struct type
> *** 558,564 ****
>        returned in a register, and if larger than 8 bytes, it is 
>        returned in a stack location which is pointed to by the same
>        register.  */
> !   CORE_ADDR return_buffer;
>     int len = TYPE_LENGTH (type);
>   
>     if (len <= (2 * 4))
> --- 558,564 ----
>        returned in a register, and if larger than 8 bytes, it is 
>        returned in a stack location which is pointed to by the same
>        register.  */
> !   gdb_byte return_buffer;
>     int len = TYPE_LENGTH (type);
>   
>     if (len <= (2 * 4))

That?  Aren't you going to run off the end of that if it's only a
single byte?

-- 
Daniel Jacobowitz
CodeSourcery


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