Skip to content

Commit

Permalink
cplc: permanent contact not skipped by lookup anymore
Browse files Browse the repository at this point in the history
- a permanently registered contact has an "expires" value of 0 in usrloc
  when processing lookup, cplc module checks that contacts are not expired by
  checking that the "expires" value of the contact is not lower than current
  time
  as a consequence, permanently registered contact are alsways skipped and
  never targeted

(cherry picked from commit 525ee13)
  • Loading branch information
easyrider14 authored and miconda committed Mar 29, 2021
1 parent 8248442 commit 631232a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/modules/cplc/cpl_run.c
Expand Up @@ -283,7 +283,7 @@ static inline char *run_lookup( struct cpl_interpreter *intr )
} else {
contact = r->contacts;
/* skip expired contacts */
while ((contact) && (contact->expires <= tc))
while ((contact) && (contact->expires > 0) && (contact->expires <= tc))
contact = contact->next;
/* any contacts left? */
if (contact) {
Expand Down

0 comments on commit 631232a

Please sign in to comment.