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
This commit is contained in:
emax 2007-03-28 21:25:56 +00:00
parent 5eebf0cb81
commit 66f5e5f292

View File

@ -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;