Avoid -Wunused-value warning

Don't use the SET_STATUS1 macro as it will always produce this
warning.  It's a rather 'interesting' macro that's probably best
avoided anyway.
上级 cbde2faa
......@@ -199,7 +199,7 @@ void authorize_watcher(nea_server_t *nes,
int substate = sn->sn_state;
int status; char const *phrase;
SET_STATUS1(SIP_200_OK);
SET_STATUS(200, sip_200_OK);
/* OK. In nhp (nua_handle_preferences_t) structure we have the
current default action (or state) for incoming
......@@ -218,10 +218,10 @@ void authorize_watcher(nea_server_t *nes,
substate = nua_substate_pending;
if (substate == nua_substate_terminated) {
what = "rejected"; SET_STATUS1(SIP_403_FORBIDDEN);
what = "rejected"; SET_STATUS(403, sip_403_Forbidden);
}
else if (substate == nua_substate_pending) {
what = "pending"; SET_STATUS1(SIP_202_ACCEPTED);
what = "pending"; SET_STATUS(202, sip_202_Accepted);
}
else {
what = "active";
......
......@@ -413,7 +413,7 @@ static int nua_publish_client_response(nua_client_request_t *cr,
if (!ex || ex->ex_delta == 0)
SET_STATUS(900, "Received Invalid Expiration Time");
else
SET_STATUS1(NUA_ERROR_AT(__FILE__, __LINE__));
SET_STATUS(900, _NUA_INTERNAL_ERROR_AT(__FILE__, __LINE__));
}
else
nua_dialog_usage_set_refresh(du, ex->ex_delta);
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论