add: remove_presentity(_d, t); free_presentity(t);
context: int timer_pdomain(pdomain_t* _d){	struct presentity* ptr, *t;	lock_pdomain(_d);	ptr = _d->first;	while(ptr) {		if (timer_presentity(ptr) < 0) {			LOG(L_ERR, "timer_pdomain(): Error in timer_pdomain\n");			unlock_pdomain(_d);			return -1;		}				     /* Remove the entire record		      * if it is empty		      */		if (ptr->watchers == 0) {			t = ptr;			ptr = ptr->next;		} else {			ptr = ptr->next;		}	}		unlock_pdomain(_d);	return 0;}