diff options
Diffstat (limited to 'net/rose')
-rw-r--r-- | net/rose/af_rose.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/net/rose/af_rose.c b/net/rose/af_rose.c index d1ff3f885c5d..1ebf65294405 100644 --- a/net/rose/af_rose.c +++ b/net/rose/af_rose.c | |||
@@ -760,8 +760,10 @@ static int rose_connect(struct socket *sock, struct sockaddr *uaddr, int addr_le | |||
760 | 760 | ||
761 | rose->neighbour = rose_get_neigh(&addr->srose_addr, &cause, | 761 | rose->neighbour = rose_get_neigh(&addr->srose_addr, &cause, |
762 | &diagnostic); | 762 | &diagnostic); |
763 | if (!rose->neighbour) | 763 | if (!rose->neighbour) { |
764 | return -ENETUNREACH; | 764 | err = -ENETUNREACH; |
765 | goto out_release; | ||
766 | } | ||
765 | 767 | ||
766 | rose->lci = rose_new_lci(rose->neighbour); | 768 | rose->lci = rose_new_lci(rose->neighbour); |
767 | if (!rose->lci) { | 769 | if (!rose->lci) { |