In function caif_sktinit_module(), the check of the return value of
sock_register() seems ineffective. This patch fixes it.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=188751
Signed-off-by: Pan Bian <redacted>
---
net/caif/caif_socket.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
@@ -1108,7 +1108,7 @@ static int caif_create(struct net *net, struct socket *sock, int protocol,staticint__initcaif_sktinit_module(void){interr=sock_register(&caif_family_ops);-if(!err)+if(err)returnerr;return0;}
From: Sergei Shtylyov <hidden> Date: 2016-12-03 13:18:02
Hello.
On 12/3/2016 2:18 PM, Pan Bian wrote:
quoted hunk
In function caif_sktinit_module(), the check of the return value of
sock_register() seems ineffective. This patch fixes it.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=188751
Signed-off-by: Pan Bian <redacted>
---
net/caif/caif_socket.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
@@ -1108,7 +1108,7 @@ static int caif_create(struct net *net, struct socket *sock, int protocol,staticint__initcaif_sktinit_module(void){interr=sock_register(&caif_family_ops);-if(!err)+if(err)returnerr;
Why not just:
return sock_register(&caif_family_ops);
From: PanBian <redacted>
Hello Sergei,
On Sat, Dec 03, 2016 at 04:17:51PM +0300, Sergei Shtylyov wrote:
Hello.
On 12/3/2016 2:18 PM, Pan Bian wrote:
quoted
In function caif_sktinit_module(), the check of the return value of
sock_register() seems ineffective. This patch fixes it.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=188751
Signed-off-by: Pan Bian <redacted>
---
net/caif/caif_socket.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
From: Sergei Shtylyov <hidden> Date: 2016-12-03 21:05:53
On 12/03/2016 06:38 PM, Pan Bian wrote:
quoted
quoted
In function caif_sktinit_module(), the check of the return value of
sock_register() seems ineffective. This patch fixes it.
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=188751
Signed-off-by: Pan Bian <redacted>
---
net/caif/caif_socket.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)