Permalink
Browse files

link: fix return code when exit path is clean

Signed-off-by: Fabio M. Di Nitto <fdinitto@redhat.com>
  • Loading branch information...
fabbione committed Jan 29, 2013
1 parent 4bc371f commit 806a3aacccdd465a2658135af2c7fa3bfbbeaf9b
Showing with 4 additions and 0 deletions.
  1. +4 −0 libknet/link.c
View
@@ -440,7 +440,11 @@ int knet_link_set_enable(knet_handle_t knet_h, uint16_t host_id, uint8_t link_id
knet_h->host_index[host_id]->name, link->status.dst_ipaddr);
err = -1;
goto exit_unlock;
+ } else {
+ err = 0;
+ savederrno = 0;
}
+
log_debug(knet_h, KNET_SUB_LINK, "host: %s link: %s is disabled",
knet_h->host_index[host_id]->name, link->status.dst_ipaddr);
link->host_info_up_sent = 0;

0 comments on commit 806a3aa

Please sign in to comment.