From: compudj@krystal.dyndns.org (Mathieu Desnoyers)
Subject: [ltt-dev] [PATCH] ltt-ascii: Fix buggy error handling
Date: Tue, 11 May 2010 07:38:00 -0400 [thread overview]
Message-ID: <20100511113800.GB12276@Krystal> (raw)
In-Reply-To: <20100306183935.GA2686@officedesk>
* Balaji Rao (balajirrao at gmail.com) wrote:
> Hi Mathieu,
>
> Fix ltt_relay_iter_open_channel to cleanup correctly on error.
Merged, thanks!
Sorry for the delay.
Mathieu
>
> Thanks,
> Balaji
>
> --
> Signed-off-by: Balaji Rao <balaji at raobalaji.com>
>
> diff --git a/ltt/ltt-ascii.c b/ltt/ltt-ascii.c
> index eeb7033..08925ea 100644
> --- a/ltt/ltt-ascii.c
> +++ b/ltt/ltt-ascii.c
> @@ -423,8 +423,11 @@ static int ltt_relay_iter_open_channel(struct ltt_relay_iter *iter,
> }
> update_cpu_iter(citer, citer->hdr_offset);
> }
> - if (!iter->nr_refs)
> - return -ENODATA; /* no data available */
> + if (!iter->nr_refs) {
> + ret = -ENODATA;
> + goto error;
> + }
> +
> return 0;
>
> error:
>
> _______________________________________________
> ltt-dev mailing list
> ltt-dev at lists.casi.polymtl.ca
> http://lists.casi.polymtl.ca/cgi-bin/mailman/listinfo/ltt-dev
>
--
Mathieu Desnoyers
Operating System Efficiency R&D Consultant
EfficiOS Inc.
http://www.efficios.com
parent reply other threads:[~2010-05-11 11:38 UTC|newest]
Thread overview: expand[flat|nested] mbox.gz Atom feed
[parent not found: <20100306183935.GA2686@officedesk>]
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=20100511113800.GB12276@Krystal \
--to=compudj@krystal.dyndns.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox