This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc 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: Remove unused variable from powerpc sem_post.c


On Tue, Dec 4, 2012 at 3:24 PM, Joseph S. Myers <joseph@codesourcery.com> wrote:
> Similar to an issue I recently fixed in the generic Linux version of
> this file, the powerpc __old_sem_post has a variable used only to
> store the result of atomic_increment_val, resulting in a warning.
> This patch fixes this warning (tested powerpc32) in the same way as
> the fix to the generic file, by casting the result of
> atomic_increment_val to (void) instead of initializing an unused
> variable with it.
>
> 2012-12-04  Joseph Myers  <joseph@codesourcery.com>
>
>         * sysdeps/unix/sysv/linux/powerpc/sem_post.c (__old_sem_post):
>         Cast result of atomic_increment_val to (void) instead of storing
>         in otherwise-unused variable.

This looks fine to me.

Ryan


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