diff options
author | emax <emax@FreeBSD.org> | 2007-03-28 21:25:56 +0000 |
---|---|---|
committer | emax <emax@FreeBSD.org> | 2007-03-28 21:25:56 +0000 |
commit | 66f5e5f2926263a961d5034c5e2aca9aabea3ac9 (patch) | |
tree | b02a36bd90660e5e8b7779f338f799d1cc47b570 | |
parent | 5eebf0cb8101ccb78b8557d40f4ad8c271488449 (diff) | |
download | FreeBSD-src-66f5e5f2926263a961d5034c5e2aca9aabea3ac9.zip FreeBSD-src-66f5e5f2926263a961d5034c5e2aca9aabea3ac9.tar.gz |
Try to silence Coverity by adding (void) in front of function call.
Also add a comment, explaining why return value is not being checked.
Requested by: netchild
MFC after: 1 week
-rw-r--r-- | sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.c | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.c b/sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.c index 2e0efe3..60bfd45 100644 --- a/sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.c +++ b/sys/netgraph/bluetooth/l2cap/ng_l2cap_cmds.c @@ -90,7 +90,17 @@ ng_l2cap_con_wakeup(ng_l2cap_con_p con) case NG_L2CAP_DISCON_RSP: case NG_L2CAP_ECHO_RSP: case NG_L2CAP_INFO_RSP: - ng_l2cap_lp_send(con, NG_L2CAP_SIGNAL_CID, m); + /* + * Do not check return ng_l2cap_lp_send() value, because + * in these cases we do not really have a graceful way out. + * ECHO and INFO responses are internal to the stack and not + * visible to user. REJect is just being nice to remote end + * (otherwise remote end will timeout anyway). DISCON is + * probably most interesting here, however, if it fails + * there is nothing we can do anyway. + */ + + (void) ng_l2cap_lp_send(con, NG_L2CAP_SIGNAL_CID, m); ng_l2cap_unlink_cmd(cmd); ng_l2cap_free_cmd(cmd); break; |