Re: [PATCH 5/4] futex: silence uninitialized warnings

From: Linus Torvalds
Date: Mon Jan 06 2014 - 21:56:05 EST


On Mon, Jan 6, 2014 at 9:38 AM, Davidlohr Bueso <davidlohr@xxxxxx> wrote:
> {
> int lock_taken, ret, force_take = 0;
> - u32 uval, newval, curval, vpid = task_pid_vnr(task);
> + u32 uval, newval, uninitialized_var(curval), vpid = task_pid_vnr(task);

Do you have some broken compiler? I really tend to hate this kind of
workarounds, because as mentioned, they can actually hide valid
warnings, and it seems to be due to just stupid compilers. Are we
perhaps better off trying to get people off the broken compiler
versions instead?

Linus
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/