* [PATCH] Sound: Core: fixed assignment in if condition style error in hwdep.c
@ 2014-06-20 15:50 Vincent Heuken
2014-06-23 16:12 ` Takashi Iwai
0 siblings, 1 reply; 2+ messages in thread
From: Vincent Heuken @ 2014-06-20 15:50 UTC (permalink / raw)
To: perex, tiwai; +Cc: alsa-devel, linux-kernel, Vincent Heuken
This is a patch to the hwdep.c file that fixes one instance of
the following error:
ERROR: do not use assignment in if condition
It also, incidentally, fixes one instance of the following warning:
WARNING: line over 80 characters
Signed-off-by: Vincent Heuken <me@vincentheuken.com>
---
sound/core/hwdep.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/sound/core/hwdep.c b/sound/core/hwdep.c
index 69459e5..42d8324 100644
--- a/sound/core/hwdep.c
+++ b/sound/core/hwdep.c
@@ -527,7 +527,9 @@ static void __init snd_hwdep_proc_init(void)
{
struct snd_info_entry *entry;
- if ((entry = snd_info_create_module_entry(THIS_MODULE, "hwdep", NULL)) != NULL) {
+ entry = snd_info_create_module_entry(THIS_MODULE, "hwdep", NULL);
+
+ if (entry != NULL) {
entry->c.text.read = snd_hwdep_proc_read;
if (snd_info_register(entry) < 0) {
snd_info_free_entry(entry);
--
2.0.0
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: [PATCH] Sound: Core: fixed assignment in if condition style error in hwdep.c
2014-06-20 15:50 [PATCH] Sound: Core: fixed assignment in if condition style error in hwdep.c Vincent Heuken
@ 2014-06-23 16:12 ` Takashi Iwai
0 siblings, 0 replies; 2+ messages in thread
From: Takashi Iwai @ 2014-06-23 16:12 UTC (permalink / raw)
To: Vincent Heuken; +Cc: perex, alsa-devel, linux-kernel
At Fri, 20 Jun 2014 08:50:35 -0700,
Vincent Heuken wrote:
>
> This is a patch to the hwdep.c file that fixes one instance of
> the following error:
> ERROR: do not use assignment in if condition
>
> It also, incidentally, fixes one instance of the following warning:
> WARNING: line over 80 characters
>
> Signed-off-by: Vincent Heuken <me@vincentheuken.com>
If this is a preliminary work for any real fix, I'd happily apply this
patch. But, if it's only about a coding style fix, I won't buy it
alone. Let me know if it's the former case.
thanks,
Takashi
> ---
> sound/core/hwdep.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/sound/core/hwdep.c b/sound/core/hwdep.c
> index 69459e5..42d8324 100644
> --- a/sound/core/hwdep.c
> +++ b/sound/core/hwdep.c
> @@ -527,7 +527,9 @@ static void __init snd_hwdep_proc_init(void)
> {
> struct snd_info_entry *entry;
>
> - if ((entry = snd_info_create_module_entry(THIS_MODULE, "hwdep", NULL)) != NULL) {
> + entry = snd_info_create_module_entry(THIS_MODULE, "hwdep", NULL);
> +
> + if (entry != NULL) {
> entry->c.text.read = snd_hwdep_proc_read;
> if (snd_info_register(entry) < 0) {
> snd_info_free_entry(entry);
> --
> 2.0.0
>
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-06-23 16:12 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-06-20 15:50 [PATCH] Sound: Core: fixed assignment in if condition style error in hwdep.c Vincent Heuken
2014-06-23 16:12 ` Takashi Iwai
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®