Patch: Elm ME+ 2.5 PLalpha46 -> Elm ME+ 2.5 PLalpha47 [3/7] (6/7)
From
Kari Hurtta@21:1/5 to
All on Sat Feb 10 14:44:54 2018
[continued from previous message]
! static int gse_rescan_name_addr(ret,now,valid_until,flag,initial_tls,was_error_p,
! cancel_p)
struct service_entry ** ret;
const struct schedule_timelimit * now;
const struct schedule_timelimit * valid_until;
int flag;
enum initial_tls_flag initial_tls;
int * was_error_p;
+ struct cancel_data ** cancel_p
+ /* May be NULL, Used if dns lookup was cancelable */;
{
int r = 0;
int expired = 0;
int was_error = *was_error_p;
struct service_entry * value = NULL;
if (SERVICE_ENTRY_magic != (*ret)->magic)
panic("CONNECTION PANIC",__FILE__,__LINE__,
"gse_rescan_name_addr",
***************
*** 2794,2800 ****
value = *ret;
inc_service_entry_refcount(value);
! if (0 != (value->flags & SE_rescan_name_addr) ||
( 0 != (value->flags & SE_given_name_addr) &&
( 0 == value->addr_count ||
(schedule_have_timelimit(now) &&
--- 2996,3007 ----
value = *ret;
inc_service_entry_refcount(value);
! if (0 != (value->flags & SE_static)) {
! DPRINT(Debug,9,(&Debug,
! "gse_rescan_name_addr: %s: rescanning skipped for static entries\n",
! value->official_name));
!
! } else if (0 != (value->flags & SE_rescan_name_addr) ||
( 0 != (value->flags & SE_given_name_addr) &&
( 0 == value->addr_count ||
(schedule_have_timelimit(now) &&
***************
*** 2845,2874 ****
value->flags &= ~SE_rescan_name_addr;
for (x = 0; x < value->addr_name_count; x++) {
!
/* Assumes that value can be changed */
! switch (service_entry_hook(&value,value->addr_name_list[x],
! NULL /* no rewrite */,
! value->service,flag,initial_tls,now,0,
! valid_until)) {
case mserv_reserved:
/* do not rescan because of reserved names! */
- was_error = 1;
break;
case mserv_not_found:
/* Should we rescan ? */
-