Found the problem we were having: the domain server was reporting back all

kinds of things as our ID.
This commit is contained in:
Andrzej Kapolka 2013-06-12 16:13:44 -07:00
parent 19180ad900
commit ccd61ee5a2
2 changed files with 18 additions and 21 deletions

View file

@ -135,8 +135,8 @@ int main(int argc, const char * argv[])
if (numInterestTypes > 0) {
// if the agent has sent no types of interest, assume they want nothing but their own ID back
for (AgentList::iterator agent = agentList->begin(); agent != agentList->end(); agent++) {
if (!agent->matches((sockaddr*) &agentPublicAddress, (sockaddr*) &agentLocalAddress, agentType)
&& memchr(agentTypesOfInterest, agent->getType(), numInterestTypes)) {
if (!agent->matches((sockaddr*) &agentPublicAddress, (sockaddr*) &agentLocalAddress, agentType)) {
if (memchr(agentTypesOfInterest, agent->getType(), numInterestTypes)) {
// this is not the agent themselves
// and this is an agent of a type in the passed agent types of interest
// or the agent did not pass us any specific types they are interested in
@ -156,6 +156,7 @@ int main(int argc, const char * argv[])
newestSoloAgents[agent->getType()] = &(*agent);
}
}
}
} else {
double timeNow = usecTimestampNow();

View file

@ -827,8 +827,6 @@ void Application::terminate() {
static void sendAvatarVoxelURLMessage(const QUrl& url) {
uint16_t ownerID = AgentList::getInstance()->getOwnerID();
qDebug() << "me" << ownerID << url;
if (ownerID == UNKNOWN_AGENT_ID) {
return; // we don't yet know who we are
}
@ -850,8 +848,6 @@ static void processAvatarVoxelURLMessage(unsigned char *packetData, size_t dataB
packetData += sizeof(agentID);
dataBytes -= sizeof(agentID);
qDebug() << "them" << agentID << QUrl::fromEncoded(QByteArray((char*)packetData, dataBytes));
// make sure the agent exists
Agent* agent = AgentList::getInstance()->agentWithID(agentID);
if (!agent || !agent->getLinkedData()) {