staging: speakup: Fix NULL comparison warning
PATCH 1/1 staging: speakup: Fix NULL comparison warning
Replace NULL comparison with '!' operator as indicated by checkpatch
Signed-off-by Daniela Mormocea <[email protected]>
--- drivers/staging/speakup/spk_ttyio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/speakup/spk_ttyio.c +1 -1
@@ -47,7 +47,7 @@ static int spk_ttyio_ldisc_open(struct tty_struct *tty) {struct spk_ldisc_data *ldisc_data; -if (tty->ops->write ==NULL ) +if (!tty->ops->write)return -EOPNOTSUPP ; speakup_tty = tty;
Signature · 1 line
2.7.4
Quoted 13 lines · Daniela Mormocea
Replace NULL comparison with '!' operator as indicated by checkpatch
Signed-off-by Daniela Mormocea <[email protected]>--- drivers/staging/speakup/spk_ttyio.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/staging/speakup/spk_ttyio.c +0
-0
drivers/staging/speakup/spk_ttyio.c static int spk_ttyio_ldisc_open(struct tty_struct *tty) · line 53
Quoted 8 lines
drivers/staging/speakup/spk_ttyio.c +1
-1@@ -47,7 +47,7 @@ static int spk_ttyio_ldisc_open(struct tty_struct *tty) {struct spk_ldisc_data *ldisc_data; -if (tty->ops->write ==NULL ) +if (!tty->ops->write)return -EOPNOTSUPP ; speakup_tty = tty;
Someone already sent this same fix to the same file just before you did, sorry.
greg k-h