• Jon Paul Maloy's avatar
    tipc: fix a loop style problem · 074bb43e
    Jon Paul Maloy authored
    In commit 7d33939f
    ("tipc: delay delete of link when failover is needed") we
    introduced a loop for finding and removing a link pointer
    in an array. The removal is done after we have left the loop,
    giving the impression that one may remove the wrong pointer
    if no matching element is found.
    
    This is not really a bug, since we know that there will always
    be a matching element, but it looks wrong, and causes a smatch
    warning.
    
    We fix this loop with this commit.
    Signed-off-by: default avatarJon Maloy <jon.maloy@ericsson.com>
    Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
    074bb43e
node.c 11.9 KB