Orignal: Packet* PacketQueue::getNext() { Packet *tmp = iter; iter = iter->next_; return tmp; } Should be: Packet* PacketQueue::getNext() { if (!iter) return NULL; Packet *tmp = iter; iter = iter->next_; return tmp; } best regards, zroger