[SR-Dev] git:master: core: pvapi uses get_hash1_raw()
Daniel-Constantin Mierla
miconda at gmail.com
Sat Apr 18 19:24:04 CEST 2009
Module: sip-router
Branch: master
Commit: 75b58438e024da69d41712e7eb05062214b09614
URL: http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=75b58438e024da69d41712e7eb05062214b09614
Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: Sat Apr 18 19:23:05 2009 +0200
core: pvapi uses get_hash1_raw()
- removed core_hash define to get_hash1_raw()
---
pvapi.c | 11 +++++------
1 files changed, 5 insertions(+), 6 deletions(-)
diff --git a/pvapi.c b/pvapi.c
index fa304a5..ed6a239 100644
--- a/pvapi.c
+++ b/pvapi.c
@@ -34,11 +34,10 @@
#include "mem/shm_mem.h"
#include "ut.h"
#include "dprint.h"
-#include "hash_func.h"
+#include "hashes.h"
#include "pvar.h"
#define is_in_str(p, in) (p<in->s+in->len && *p)
-#define core_hash(in, a, b) get_hash1_raw((in)->s, (in)->len)
#define PV_TABLE_SIZE 16
#define TR_TABLE_SIZE 4
@@ -113,7 +112,7 @@ int pv_table_add(pv_export_t *e)
}
found = 0;
//pvid = get_hash1_raw(in->s, in->len);
- pvid = core_hash(in, 0, 0);
+ pvid = get_hash1_raw(in->s, in->len);
pvi = _pv_table[pvid%PV_TABLE_SIZE];
while(pvi)
@@ -325,7 +324,7 @@ pv_export_t* pv_lookup_spec_name(str *pvname, pv_spec_p e)
/* search in PV table */
// pvid = get_hash1_raw(pvname->s, pvname->len);
- pvid = core_hash(pvname, 0, 0);
+ pvid = get_hash1_raw(pvname->s, pvname->len);
pvi = _pv_table[pvid%PV_TABLE_SIZE];
while(pvi)
{
@@ -1357,7 +1356,7 @@ int tr_table_add(tr_export_t *e)
found = 0;
// trid = get_hash1_raw(e->tclass.s, e->tclass.len);
- trid = core_hash(&e->tclass, 0, 0);
+ trid = get_hash1_raw(e->tclass.s, e->tclass.len);
tri = _tr_table[trid%TR_TABLE_SIZE];
while(tri)
@@ -1460,7 +1459,7 @@ tr_export_t* tr_lookup_class(str *tclass)
/* search in TR table */
// trid = get_hash1_raw(tclass->s, tclass->len);
- trid = core_hash(tclass, 0, 0);
+ trid = get_hash1_raw(tclass->s, tclass->len);
tri = _tr_table[trid%TR_TABLE_SIZE];
while(tri)
{
More information about the sr-dev
mailing list