All of lore.kernel.org
 help / color / mirror / Atom feed
From: Wei Liu <wei.liu2@citrix.com>
To: Ian Campbell <ian.campbell@citrix.com>
Cc: wei.liu2@citrix.com, ian.jackson@eu.citrix.com, xen-devel@lists.xen.org
Subject: Re: [PATCH] tools: xenconsole: cleanup when clock_gettime fails.
Date: Wed, 3 Feb 2016 10:49:08 +0000	[thread overview]
Message-ID: <20160203104908.GG23178@citrix.com> (raw)
In-Reply-To: <1454496227-24376-1-git-send-email-ian.campbell@citrix.com>

On Wed, Feb 03, 2016 at 10:43:47AM +0000, Ian Campbell wrote:
> All other error paths in the infinite loop in handle_io use break, so
> as to free resources.
> 
> CID: 1351226
> 
> Signed-off-by: Ian Campbell <ian.campbell@citrix.com>

Acked-by: Wei Liu <wei.liu2@citrix.com>

> ---
>  tools/console/daemon/io.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/tools/console/daemon/io.c b/tools/console/daemon/io.c
> index e2e7a6b..34666c4 100644
> --- a/tools/console/daemon/io.c
> +++ b/tools/console/daemon/io.c
> @@ -1053,7 +1053,7 @@ void handle_io(void)
>  						 POLLIN|POLLPRI);
>  
>  		if (clock_gettime(CLOCK_MONOTONIC, &ts) < 0)
> -			return;
> +			break;
>  		now = ((long long)ts.tv_sec * 1000) + (ts.tv_nsec / 1000000);
>  
>  		/* Re-calculate any event counter allowances & unblock
> -- 
> 2.1.4
> 

  reply	other threads:[~2016-02-03 10:49 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-02-03 10:43 [PATCH] tools: xenconsole: cleanup when clock_gettime fails Ian Campbell
2016-02-03 10:49 ` Wei Liu [this message]
2016-02-03 11:49   ` Ian Campbell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20160203104908.GG23178@citrix.com \
    --to=wei.liu2@citrix.com \
    --cc=ian.campbell@citrix.com \
    --cc=ian.jackson@eu.citrix.com \
    --cc=xen-devel@lists.xen.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.