qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH][RFC] Fix gcc 4.x warnings (-Wpointer-sign)


From: Blue Swirl
Subject: Re: [Qemu-devel] [PATCH][RFC] Fix gcc 4.x warnings (-Wpointer-sign)
Date: Sat, 13 Sep 2008 09:38:29 +0300

On 9/12/08, M. Warner Losh <address@hidden> wrote:
> In message: <address@hidden>
>             "Blue Swirl" <address@hidden> writes:
>  : GCC 4 enables -Wpointer-sign if -Wall is enabled. This trivial patch
>
> : suppresses the warnings. Comments? Objections?
>
>
> Don't you mean 'fix' the warnings, since this patch looks like it
>  tries to cast things to be correct...

Well, some parts of the patch actually fix the types so that they are
more consistent, the casts just silence the warnings. A real fix would
be to change the types but then it would be incorrect to change the
signed types just to match the unsigned loadvm/savevm API.

Now that I think of it, the API could be extended with signed
versions. That would be best in terms of type safety. Maybe I'll try
that approach instead.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]