Integration with libbitdht.

* Added debuging #defs for annoying output.
 * fixed compiler "unused parameter" warning for rsiface.h



git-svn-id: http://svn.code.sf.net/p/retroshare/code/trunk@3327 b45a01b8-16f6-495d-af2f-9b41ad6348cc
This commit is contained in:
drbob 2010-08-01 18:22:37 +00:00
parent f876dcb93b
commit 74b36a6af6
4 changed files with 29 additions and 12 deletions

View file

@ -265,8 +265,10 @@ int p3BitDht::lookupRsId(const bdNodeId *id, std::string &pid)
nit = mTransToRsId.find(*id);
if (nit == mTransToRsId.end())
{
#ifdef DEBUG_BITDHT
std::cerr << "p3BitDht::lookupRsId() failed";
std::cerr << std::endl;
#endif
return 0;
}
@ -319,8 +321,10 @@ int p3BitDht::removeTranslation(const std::string pid)
/********************** Callback Functions **************************/
int p3BitDht::NodeCallback(const bdId *id, uint32_t peerflags)
{
#ifdef DEBUG_BITDHT
std::cerr << "p3BitDht::NodeCallback()";
std::cerr << std::endl;
#endif
/* is it one that we are interested in? */
std::string pid;
@ -330,6 +334,13 @@ int p3BitDht::NodeCallback(const bdId *id, uint32_t peerflags)
/* we found it ... do callback to p3connmgr */
//uint32_t cbflags = ONLINE | UNREACHABLE;
for(int i = 0; i < 10; i++)
{
std::cerr << "p3BitDht::NodeCallback() FOUND NODE!!!: ";
std::cerr << pid << " flags: " << peerflags;
std::cerr << std::endl;
}
return 1;
}