RE: [PATCH] eliminate compiler warning for xpc_channel.c
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
- To: "Matthew Wilcox" <matthew@xxxxxx>
- Subject: RE: [PATCH] eliminate compiler warning for xpc_channel.c
- From: "Luck, Tony" <tony.luck@xxxxxxxxx>
- Date: Tue, 4 Apr 2006 07:34:08 -0700
- Cc: "Dean Nelson" <dcn@xxxxxxx>, <linux-ia64@xxxxxxxxxxxxxxx>
- Thread-index: AcZX8/lIzmM6I2M2SnSkOTbgEuytEAAAG0Zg
- Thread-topic: [PATCH] eliminate compiler warning for xpc_channel.c
>> Did you mean to say "*msg = NULL"?
>
> this is actually an ANSI-permitted idiom for shutting up compiler
> warnings while not actually initialising the variable.
So I learned something new today!
But then this patch is wrong ... it shuts the compiler up
and leaves 4 ways that xpc_allocate_msg() can return without doing
the initialization, so that msg will be used uninitialized.
-Tony
-
: send the line "unsubscribe linux-ia64" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
[Index of Archives]
[Linux Kernel]
[Sparc Linux]
[DCCP]
[Linux ARM]
[Yosemite News]
[Linux SCSI]
[Linux x86_64]
[Linux for Ham Radio]