[CRIU] [PATCH 1/7] iters: Shorten logging

Adrian Reber adrian at lisas.de
Fri Oct 23 01:49:58 PDT 2015


Acked-by: Adrian Reber <adrian at lisas.de>

On Thu, Oct 22, 2015 at 03:45:24PM +0300, Pavel Emelyanov wrote:
> Signed-off-by: Pavel Emelyanov <xemul at parallels.com>
> ---
>  phaul/p_haul_iters.py | 11 ++---------
>  1 file changed, 2 insertions(+), 9 deletions(-)
> 
> diff --git a/phaul/p_haul_iters.py b/phaul/p_haul_iters.py
> index b2c76e3..0dd56cc 100644
> --- a/phaul/p_haul_iters.py
> +++ b/phaul/p_haul_iters.py
> @@ -115,22 +115,15 @@ class phaul_iter_worker:
>  			# pre-dump auto-detection
>  			try:
>  				self.pre_dump = self.pre_dump_check()
> -				if self.pre_dump:
> -					logging.info("\t`- Auto Enabled")
> -				else:
> -					logging.info("\t`- Auto Disabled")
> -
> +				logging.info("\t`- Auto %s" % (self.pre_dump and 'enabled' or 'disabled'))
>  			except:
>  				# The available criu seems to not
>  				# support memory tracking auto detection.
>  				self.pre_dump = PRE_DUMP_DISABLE
>  				logging.info("\t`- Auto detection not possible "
>  						"- Disabled")
> -
> -		elif self.pre_dump == PRE_DUMP_DISABLE:
> -			logging.info("\t`- Command-line disabled")
>  		else:
> -			logging.info("\t`- Command-line enabled")
> +			logging.info("\t`- Command-line %s" % (self.pre_dump and 'enabled' or 'disabled'))
>  
>  		if self.pre_dump:
>  			logging.info("Starting iterations")
> -- 
> 1.9.3


More information about the CRIU mailing list