Skip to content

Commit

Permalink
htable Change error messages from "$ht" to "$sht"
Browse files Browse the repository at this point in the history
  • Loading branch information
oej committed Oct 4, 2015
1 parent 4da31d5 commit 4e75880
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 20 deletions.
24 changes: 12 additions & 12 deletions modules/htable/ht_var.c
Expand Up @@ -44,7 +44,7 @@ int pv_get_ht_cell(struct sip_msg *msg, pv_param_t *param,
}
if(pv_printf_s(msg, hpv->pve, &htname)!=0)
{
LM_ERR("cannot get $ht name\n");
LM_ERR("cannot get $sht name\n");
return -1;
}
htc = ht_cell_pkg_copy(hpv->ht, &htname, _htc_local);
Expand Down Expand Up @@ -83,10 +83,10 @@ int pv_set_ht_cell(struct sip_msg* msg, pv_param_t *param,

if(pv_printf_s(msg, hpv->pve, &htname)!=0)
{
LM_ERR("cannot get $ht name\n");
LM_ERR("cannot get $sht name\n");
return -1;
}
LM_DBG("set value for $ht(%.*s=>%.*s)\n", hpv->htname.len, hpv->htname.s,
LM_DBG("set value for $sht(%.*s=>%.*s)\n", hpv->htname.len, hpv->htname.s,
htname.len, htname.s);
if((val==NULL) || (val->flags&PV_VAL_NULL))
{
Expand All @@ -106,7 +106,7 @@ int pv_set_ht_cell(struct sip_msg* msg, pv_param_t *param,
}
if(ht_set_cell(hpv->ht, &htname, 0, &isval, 1)!=0)
{
LM_ERR("cannot set $ht(%.*s)\n", htname.len, htname.s);
LM_ERR("cannot set $sht(%.*s)\n", htname.len, htname.s);
return -1;
}
} else {
Expand All @@ -116,7 +116,7 @@ int pv_set_ht_cell(struct sip_msg* msg, pv_param_t *param,
}
if(ht_set_cell(hpv->ht, &htname, AVP_VAL_STR, &isval, 1)!=0)
{
LM_ERR("cannot set $ht(%.*s)\n", htname.len, htname.s);
LM_ERR("cannot set $sht(%.*s)\n", htname.len, htname.s);
return -1;
}
}
Expand Down Expand Up @@ -203,7 +203,7 @@ int pv_get_ht_cell_expire(struct sip_msg *msg, pv_param_t *param,
}
if(pv_printf_s(msg, hpv->pve, &htname)!=0)
{
LM_ERR("cannot get $ht name\n");
LM_ERR("cannot get $sht name\n");
return -1;
}
if(ht_get_cell_expire(hpv->ht, &htname, &now)!=0)
Expand All @@ -228,10 +228,10 @@ int pv_set_ht_cell_expire(struct sip_msg* msg, pv_param_t *param,

if(pv_printf_s(msg, hpv->pve, &htname)!=0)
{
LM_ERR("cannot get $ht name\n");
LM_ERR("cannot get $sht name\n");
return -1;
}
LM_DBG("set expire value for $ht(%.*s=>%.*s)\n", hpv->htname.len,
LM_DBG("set expire value for $sht(%.*s=>%.*s)\n", hpv->htname.len,
hpv->htname.s, htname.len, htname.s);
isval.n = 0;
if(val!=NULL)
Expand All @@ -244,7 +244,7 @@ int pv_set_ht_cell_expire(struct sip_msg* msg, pv_param_t *param,
}
if(ht_set_cell_expire(hpv->ht, &htname, 0, &isval)!=0)
{
LM_ERR("cannot set $ht(%.*s)\n", htname.len, htname.s);
LM_ERR("cannot set $sht(%.*s)\n", htname.len, htname.s);
return -1;
}

Expand All @@ -268,7 +268,7 @@ int pv_get_ht_cn(struct sip_msg *msg, pv_param_t *param,
}
if(pv_printf_s(msg, hpv->pve, &htname)!=0)
{
LM_ERR("cannot get $ht name\n");
LM_ERR("cannot get $sht name\n");
return -1;
}

Expand All @@ -295,7 +295,7 @@ int pv_get_ht_cv(struct sip_msg *msg, pv_param_t *param,
}
if(pv_printf_s(msg, hpv->pve, &htname)!=0)
{
LM_ERR("cannot get $ht name\n");
LM_ERR("cannot get $sht name\n");
return -1;
}

Expand All @@ -322,7 +322,7 @@ int pv_get_ht_add(struct sip_msg *msg, pv_param_t *param,
}
if(pv_printf_s(msg, hpv->pve, &htname)!=0)
{
LM_ERR("cannot get $ht name\n");
LM_ERR("cannot get $sht name\n");
return -1;
}
htc = ht_cell_value_add(hpv->ht, &htname, val, 1, _htc_local);
Expand Down
16 changes: 8 additions & 8 deletions modules/htable/htable.c
Expand Up @@ -326,7 +326,7 @@ static int ht_rm_name_re(struct sip_msg* msg, char* key, char* foo)
}
if(pv_printf_s(msg, hpv->pve, &sre)!=0)
{
LM_ERR("cannot get $ht expression\n");
LM_ERR("cannot get $sht expression\n");
return -1;
}
if (hpv->ht->dmqreplicate>0) {
Expand Down Expand Up @@ -358,7 +358,7 @@ static int ht_rm_value_re(struct sip_msg* msg, char* key, char* foo)
}
if(pv_printf_s(msg, hpv->pve, &sre)!=0)
{
LM_ERR("cannot get $ht expression\n");
LM_ERR("cannot get $sht expression\n");
return -1;
}

Expand Down Expand Up @@ -462,13 +462,13 @@ static int w_ht_slot_lock(struct sip_msg* msg, char* key, char* foo)
{
hpv->ht = ht_get_table(&hpv->htname);
if(hpv->ht==NULL) {
LM_ERR("cannot get $ht root\n");
LM_ERR("cannot get $sht root\n");
return -11;
}
}
if(pv_printf_s(msg, hpv->pve, &skey)!=0)
{
LM_ERR("cannot get $ht key\n");
LM_ERR("cannot get $sht key\n");
return -1;
}

Expand Down Expand Up @@ -504,13 +504,13 @@ static int w_ht_slot_unlock(struct sip_msg* msg, char* key, char* foo)
{
hpv->ht = ht_get_table(&hpv->htname);
if(hpv->ht==NULL) {
LM_ERR("cannot get $ht root\n");
LM_ERR("cannot get $sht root\n");
return -11;
}
}
if(pv_printf_s(msg, hpv->pve, &skey)!=0)
{
LM_ERR("cannot get $ht key\n");
LM_ERR("cannot get $sht key\n");
return -1;
}

Expand Down Expand Up @@ -896,7 +896,7 @@ static void htable_rpc_sets(rpc_t* rpc, void* c) {

if(ht_set_cell(ht, &keyname, AVP_VAL_STR, &keyvalue, 1)!=0)
{
LM_ERR("cannot set $ht(%.*s=>%.*s)\n", htname.len, htname.s,
LM_ERR("cannot set $sht(%.*s=>%.*s)\n", htname.len, htname.s,
keyname.len, keyname.s);
rpc->fault(c, 500, "Failed to set the item");
return;
Expand Down Expand Up @@ -930,7 +930,7 @@ static void htable_rpc_seti(rpc_t* rpc, void* c) {

if(ht_set_cell(ht, &keyname, 0, &keyvalue, 1)!=0)
{
LM_ERR("cannot set $ht(%.*s=>%.*s)\n", htname.len, htname.s,
LM_ERR("cannot set $sht(%.*s=>%.*s)\n", htname.len, htname.s,
keyname.len, keyname.s);
rpc->fault(c, 500, "Failed to set the item");
return;
Expand Down

0 comments on commit 4e75880

Please sign in to comment.