IRDA: irda_create() nuke user triggable printk
authormaximilian attems <max@stro.at>
Fri, 11 Jan 2008 09:14:17 +0000 (01:14 -0800)
committerGreg Kroah-Hartman <gregkh@suse.de>
Wed, 6 Feb 2008 19:43:41 +0000 (11:43 -0800)
[IRDA]: irda_create() nuke user triggable printk

[ Upstream commit: 9e8d6f8959c356d8294d45f11231331c3e1bcae6 ]

easy to trigger as user with sfuzz.

irda_create() is quiet on unknown sock->type,
match this behaviour for SOCK_DGRAM unknown protocol

Signed-off-by: maximilian attems <max@stro.at>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
net/irda/af_irda.c

index dcd7e325b283cc66885aef639b92424df473769d..73708b598cf2ab1b63f23296efe84b408ef2b1e5 100644 (file)
@@ -1115,8 +1115,6 @@ static int irda_create(struct socket *sock, int protocol)
                        self->max_sdu_size_rx = TTP_SAR_UNBOUND;
                        break;
                default:
-                       IRDA_ERROR("%s: protocol not supported!\n",
-                                  __FUNCTION__);
                        return -ESOCKTNOSUPPORT;
                }
                break;