diff options
author | Dave Wallace <dwallacelf@gmail.com> | 2023-08-22 23:42:02 -0400 |
---|---|---|
committer | Andrew Yourtchenko <ayourtch@gmail.com> | 2023-09-13 15:50:15 +0000 |
commit | 7f9b690b06571da41400925c17b2e7de86f746f6 (patch) | |
tree | 0ea16b190730daed2972b7f95d9519bc0f54d370 /src/vlibmemory/socket_api.c | |
parent | 7bf8f5e484a49fd90db1c4c4e38d82810bddada8 (diff) |
api: fix vlibmemory coverity warning CID-300152
Type: fix
Change-Id: Icdebc8629946e0e7c8dde3e45ee93ff9027e7c68
Signed-off-by: Dave Wallace <dwallacelf@gmail.com>
Diffstat (limited to 'src/vlibmemory/socket_api.c')
-rw-r--r-- | src/vlibmemory/socket_api.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/vlibmemory/socket_api.c b/src/vlibmemory/socket_api.c index 24a460979f4..c139b652609 100644 --- a/src/vlibmemory/socket_api.c +++ b/src/vlibmemory/socket_api.c @@ -288,6 +288,10 @@ vl_socket_read_ready (clib_file_t * uf) } rp = vl_socket_get_registration (reg_index); + if (!rp) + { + return 0; + } /* Ignore unprocessed_input for now, n describes input_buffer for now. */ n = read (uf->file_descriptor, socket_main.input_buffer, |