Skip to content

Commit

Permalink
Update deprecated macroses
Browse files Browse the repository at this point in the history
  • Loading branch information
vankoven committed May 25, 2019
1 parent ce8d74d commit 0b1be60
Show file tree
Hide file tree
Showing 2 changed files with 91 additions and 91 deletions.
14 changes: 7 additions & 7 deletions tempesta_fw/http_limits.c
Original file line number Diff line number Diff line change
Expand Up @@ -252,7 +252,7 @@ typedef struct {
do { \
char abuf[TFW_ADDR_STR_BUF_SIZE] = {0}; \
tfw_addr_fmt(addr, TFW_NO_PORT, abuf); \
TFW_DBG("frang: " fmt_msg, abuf, ##__VA_ARGS__); \
T_DBG("frang: " fmt_msg, abuf, ##__VA_ARGS__); \
} while (0)
#else
#define frang_dbg(...)
Expand Down Expand Up @@ -336,7 +336,7 @@ frang_conn_new(struct sock *sk)
ss_getpeername(sk, &addr);
cli = tfw_client_obtain(addr, NULL, NULL, __frang_init_acc);
if (unlikely(!cli)) {
TFW_ERR("can't obtain a client for frang accounting\n");
T_ERR("can't obtain a client for frang accounting\n");
tfw_vhost_put(dflt_vh);
return TFW_BLOCK;
}
Expand Down Expand Up @@ -614,7 +614,7 @@ frang_http_host_check(const TfwHttpReq *req, FrangAcc *ra)

hdrhost = tfw_pool_alloc(req->pool, field.len + 1);
if (unlikely(!hdrhost)) {
TFW_ERR("Can not allocate memory\n");
T_ERR("Can not allocate memory\n");
return TFW_BLOCK;
}
tfw_str_to_cstr(&field, hdrhost, field.len + 1);
Expand Down Expand Up @@ -1267,7 +1267,7 @@ tfw_http_limits_hooks_register(void)
h->hook_state, h->fsm_id,
h->st0);
if (h->prio < 0) {
TFW_ERR_NL("frang: can't register %s hook\n", h->name);
T_ERR_NL("frang: can't register %s hook\n", h->name);
return -EINVAL;
}
}
Expand All @@ -1288,13 +1288,13 @@ tfw_http_limits_init(void)

r = tfw_gfsm_register_fsm(TFW_FSM_FRANG_REQ, frang_http_req_handler);
if (r) {
TFW_ERR_NL("frang: can't register request fsm\n");
T_ERR_NL("frang: can't register request fsm\n");
goto err_fsm;
}

r = tfw_gfsm_register_fsm(TFW_FSM_FRANG_RESP, frang_resp_handler);
if (r) {
TFW_ERR_NL("frang: can't register response fsm\n");
T_ERR_NL("frang: can't register response fsm\n");
goto err_fsm_resp;
}

Expand All @@ -1317,7 +1317,7 @@ tfw_http_limits_init(void)
void
tfw_http_limits_exit(void)
{
TFW_DBG("frang exit\n");
T_DBG("frang exit\n");

tfw_http_limits_hooks_remove();
tfw_gfsm_unregister_fsm(TFW_FSM_FRANG_RESP);
Expand Down
Loading

0 comments on commit 0b1be60

Please sign in to comment.