aboutsummaryrefslogtreecommitdiffstats
path: root/net/rose/af_rose.c
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2006-12-14 18:50:34 -0500
committerDavid S. Miller <davem@sunset.davemloft.net>2006-12-18 00:59:09 -0500
commit81dcd1690697efbdf8126e78fbbf7c76d359377f (patch)
treee4408697d6e40efed6f876b7bcd133fdc93c7eb5 /net/rose/af_rose.c
parent8d5cf596d10d740b69b5f4bbdb54b85abf75810d (diff)
[AX.25]: Fix unchecked ax25_listen_register uses
Fix ax25_listen_register to return something that's a sane error code, then all callers to use it. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/rose/af_rose.c')
-rw-r--r--net/rose/af_rose.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/net/rose/af_rose.c b/net/rose/af_rose.c
index 1605069e5db1..09f8a06bf806 100644
--- a/net/rose/af_rose.c
+++ b/net/rose/af_rose.c
@@ -1314,7 +1314,8 @@ static int rose_ioctl(struct socket *sock, unsigned int cmd, unsigned long arg)
1314 if (copy_from_user(&rose_callsign, argp, sizeof(ax25_address))) 1314 if (copy_from_user(&rose_callsign, argp, sizeof(ax25_address)))
1315 return -EFAULT; 1315 return -EFAULT;
1316 if (ax25cmp(&rose_callsign, &null_ax25_address) != 0) 1316 if (ax25cmp(&rose_callsign, &null_ax25_address) != 0)
1317 ax25_listen_register(&rose_callsign, NULL); 1317 return ax25_listen_register(&rose_callsign, NULL);
1318
1318 return 0; 1319 return 0;
1319 1320
1320 case SIOCRSGL2CALL: 1321 case SIOCRSGL2CALL: