author | Michael Krelin <hacker@klever.net> | 2008-02-11 21:16:26 (UTC) |
---|---|---|
committer | Michael Krelin <hacker@klever.net> | 2008-02-11 21:16:26 (UTC) |
commit | 947098ee2ab09c340e6822f2bfce7570388c86b4 (patch) (side-by-side diff) | |
tree | bcf221248e6196ce39b073866727b55e56c2dd57 | |
parent | 4cd6cad3b5fda6eb09c8c36efeb9426316f35a37 (diff) | |
download | libopkele-947098ee2ab09c340e6822f2bfce7570388c86b4.zip libopkele-947098ee2ab09c340e6822f2bfce7570388c86b4.tar.gz libopkele-947098ee2ab09c340e6822f2bfce7570388c86b4.tar.bz2 |
removed obsoleted functions in test RP
Signed-off-by: Michael Krelin <hacker@klever.net>
-rw-r--r-- | test/RP.cc | 28 |
1 files changed, 0 insertions, 28 deletions
@@ -230,76 +230,48 @@ class example_rp_t : public opkele::prequeue_RP { assert(nr==1); assert(nc==3); eqtop.uri = T.get(1,0,nc); eqtop.claimed_id = T.get(1,1,nc); eqtop.local_id = T.get(1,2,nc); have_eqtop = true; } return eqtop; } void next_endpoint() { assert(as_id>=0); get_endpoint(); have_eqtop = false; sqlite3_mem_t<char*> S = sqlite3_mprintf( "DELETE FROM endpoints_queue" " WHERE as_id=%ld AND eq_uri=%Q AND eq_local_id=%Q", htc.get_value().c_str(),as_id, eqtop.uri.c_str()); db.exec(S); } mutable string _cid; mutable string _nid; - void set_claimed_id(const string& cid) { - assert(as_id>=0); - sqlite3_mem_t<char*> S = sqlite3_mprintf( - "UPDATE auth_sessions" - " SET as_claimed_id=%Q" - " WHERE hts_id=%Q and as_id=%ld", - cid.c_str(), - htc.get_value().c_str(),as_id); - db.exec(S); - _cid = cid; - } - const string get_claimed_id() const { - assert(as_id>=0); - if(_cid.empty()) { - sqlite3_mem_t<char*> S = sqlite3_mprintf( - "SELECT as_claimed_id" - " FROM" - " auth_sessions" - " WHERE" - " hts_id=%Q AND as_id=%ld", - htc.get_value().c_str(),as_id); - sqlite3_table_t T; int nr,nc; - db.get_table(S,T,&nr,&nc); - assert(nr==1); assert(nc==1); - _cid = T.get(1,0,nc); - } - return _cid; - } void set_normalized_id(const string& nid) { assert(as_id>=0); sqlite3_mem_t<char*> S = sqlite3_mprintf( "UPDATE auth_sessions" " SET as_normalized_id=%Q" " WHERE hts_id=%Q and as_id=%ld", nid.c_str(), htc.get_value().c_str(),as_id); db.exec(S); _nid = nid; } const string get_normalized_id() const { assert(as_id>=0); if(_nid.empty()) { sqlite3_mem_t<char*> S = sqlite3_mprintf( "SELECT as_normalized_id" " FROM" " auth_sessions" " WHERE" " hts_id=%Q AND as_id=%ld", htc.get_value().c_str(),as_id); sqlite3_table_t T; int nr,nc; db.get_table(S,T,&nr,&nc); assert(nr==1); assert(nc==1); |