diff options
| author | Quentin Young <qlyoung@users.noreply.github.com> | 2018-06-28 12:55:25 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2018-06-28 12:55:25 -0400 |
| commit | d55c2456e85fde40b7411f8d4f64080f8a110fbc (patch) | |
| tree | c743a2abfe1e7d177710799f6d973f699f5d627b | |
| parent | 1db6d244973c1dd81e1c8819c16ce3281a4c2d7e (diff) | |
| parent | b684aedac8bebf039e1223752fb3190217f89b2f (diff) | |
Merge pull request #2576 from pacovn/Coverity_1399228_Logically_dead_code
bgpd: dead code (Coverity 1399228)
| -rw-r--r-- | bgpd/rfapi/rfapi_vty.c | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/bgpd/rfapi/rfapi_vty.c b/bgpd/rfapi/rfapi_vty.c index 18a979e531..2f8f132fcd 100644 --- a/bgpd/rfapi/rfapi_vty.c +++ b/bgpd/rfapi/rfapi_vty.c @@ -388,15 +388,11 @@ int rfapiStream2Vty(void *stream, /* input */ return 1; } - if (stream) { - *vty = stream; /* VTYNL requires vty to be legit */ - *fp = (int (*)(void *, const char *, ...))vty_out; - *outstream = stream; - *vty_newline = str_vty_newline(*vty); - return 1; - } - - return 0; + *vty = stream; /* VTYNL requires vty to be legit */ + *fp = (int (*)(void *, const char *, ...))vty_out; + *outstream = stream; + *vty_newline = str_vty_newline(*vty); + return 1; } /* called from bgpd/bgp_vty.c'route_vty_out() */ |
