[sr-dev] git:tmp/ims_usrloc_pcscf_db_support: modules/ims_usrloc_pcscf: removed commented code

Jason Penton jason.penton at gmail.com
Fri Nov 29 10:12:38 CET 2013


Module: sip-router
Branch: tmp/ims_usrloc_pcscf_db_support
Commit: a72d58f85c75bb1b70b170f7aeda2a8952dc2296
URL:    http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=a72d58f85c75bb1b70b170f7aeda2a8952dc2296

Author: Jason Penton <jason.penton at gmail.com>
Committer: Jason Penton <jason.penton at gmail.com>
Date:   Fri Nov 29 11:11:53 2013 +0200

modules/ims_usrloc_pcscf: removed commented code

---

 modules/ims_usrloc_pcscf/usrloc_db.c |   10 ++--------
 1 files changed, 2 insertions(+), 8 deletions(-)

diff --git a/modules/ims_usrloc_pcscf/usrloc_db.c b/modules/ims_usrloc_pcscf/usrloc_db.c
index 6c0fb87..7d55df3 100644
--- a/modules/ims_usrloc_pcscf/usrloc_db.c
+++ b/modules/ims_usrloc_pcscf/usrloc_db.c
@@ -99,8 +99,6 @@ int use_location_pcscf_table(str* domain)
 
 int db_update_pcontact(pcontact_t* _c)
 {
-//	char buf[2048];	//TODO: use re-usable pkg mem...
-//	char buf2[2048]; //TODO: use re-usable pkg mem...
 	str impus, service_routes;
 
 	db_val_t match_values[1];
@@ -207,8 +205,6 @@ int db_delete_pcontact(pcontact_t* _c)
 int db_insert_pcontact(struct pcontact* _c)
 {
 	str empty_str = str_init("");
-	char buf[2048];		//TODO: use re-usable pkg mem...
-	char buf2[2048];	//TODO: use re-usable pkg mem...
 	str impus, service_routes;
 
 	db_key_t keys[13] = {
@@ -223,7 +219,6 @@ int db_insert_pcontact(struct pcontact* _c)
 	};
 	db_val_t values[13];
 
-//	VAL_TYPE(GET_FIELD_IDX(values, LP_ID_IDX)) = DB1_INT;
 	VAL_TYPE(GET_FIELD_IDX(values, LP_DOMAIN_IDX)) = DB1_STR;
 	VAL_TYPE(GET_FIELD_IDX(values, LP_AOR_IDX)) = DB1_STR;
 	VAL_TYPE(GET_FIELD_IDX(values, LP_CONTACT_IDX)) = DB1_STR;
@@ -279,13 +274,13 @@ int db_insert_pcontact(struct pcontact* _c)
 
 	/* add the public identities */
 	impus.len = impus_as_string(_c, &impu_buffer);
-	impus.s = buf;
+	impus.s = impu_buffer.buf;
 	SET_PROPER_NULL_FLAG(impus, values, LP_PUBLIC_IPS_IDX);
 	SET_STR_VALUE(GET_FIELD_IDX(values, LP_PUBLIC_IPS_IDX), impus);
 
 	/* add service routes */
 	service_routes.len = service_routes_as_string(_c, &service_route_buffer);
-	service_routes.s = buf2;
+	service_routes.s = service_route_buffer.buf;
 	SET_PROPER_NULL_FLAG(service_routes, values, LP_PUBLIC_IPS_IDX);
 	SET_STR_VALUE(GET_FIELD_IDX(values, LP_PUBLIC_IPS_IDX), service_routes);
 
@@ -378,7 +373,6 @@ int service_routes_as_string(struct pcontact* _c, t_reusable_buffer *buffer) {
 		p+=_c->service_routes[i].len;
 		*p = '>';
 		p++;
-//		len += _c->service_routes[i].len + 2;
 	}
 
 	return len;




More information about the sr-dev mailing list