/// Called upon network scanner thread completion.
Called upon network scanner thread completion.
Called upon network scanner thread completion .
fn scan_completed(&mut self) {
        let res = match self.scanner.take() {
            Some(handle) => handle.join(),
            _ => Ok(()),
        };
        let mut app_context = self.app_context.lock()
            .unwrap();
        {
            let config          = &mut app_context.config;
            let active_services = config.active_services();
            if self.active_services != active_services {
                self.active_services = active_services;
                config.bump_version();
            }
            utils::result_or_log(&mut self.logger, Severity::WARN,
                format!("unable to save config file \"{}\"", self.config_file),
                config.save(&self.config_file));
        }
        app_context.scanning = false;
        if res.is_err() {
            log_warn!(self.logger, "network scanner thread panicked");
        }
    }
fn scan_completed ( & mut self ) { let res = match self . scanner . take ( ) { Some ( handle ) => handle . join ( ) , _ => Ok ( ( ) ) , } ; let mut app_context = self . app_context . lock ( ) . unwrap ( ) ; { let config = & mut app_context . config ; let active_services = config . active_services ( ) ; if self . active_services != active_services { self . active_services = active_services ; config . bump_version ( ) ; } utils :: result_or_log ( & mut self . logger , Severity :: WARN , format ! ( " \" \" " self config_file ) , config . save ( & self . config_file ) ) ; } app_context . scanning = false ; if res . is_err ( ) { log_warn ! ( self logger " " ) ; } }
Called upon network scanner thread completion.
Called upon network scanner thread completion .
&mut self