util-linux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Karel Zak <kzak@redhat.com>
To: Cong Wang <amwang@redhat.com>
Cc: util-linux@vger.kernel.org, Cong Wang <xiyou.wangcong@gmail.com>
Subject: Re: [Patch] lib/sysfs.c: check if cxt->dir_path is NULL in sysfs_readlink()
Date: Thu, 21 Jun 2012 10:43:15 +0200	[thread overview]
Message-ID: <20120621084315.GA16949@x2.net.home> (raw)
In-Reply-To: <1340181120-3457-1-git-send-email-amwang@redhat.com>

On Wed, Jun 20, 2012 at 04:32:00PM +0800, Cong Wang wrote:
> cxt->dir_path could be NULL, for example, when sysfs_init() fails,
> check this before calling readlink()/readlink_at().

 Applied, thanks.

 I have also added warn_unused_result attribute to sysfs_init() to
 make sure that cxt is everywhere initialized.

    Karel

-- 
 Karel Zak  <kzak@redhat.com>
 http://karelzak.blogspot.com

      reply	other threads:[~2012-06-21  8:43 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-20  8:32 [Patch] lib/sysfs.c: check if cxt->dir_path is NULL in sysfs_readlink() Cong Wang
2012-06-21  8:43 ` Karel Zak [this message]

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=20120621084315.GA16949@x2.net.home \
    --to=kzak@redhat.com \
    --cc=amwang@redhat.com \
    --cc=util-linux@vger.kernel.org \
    --cc=xiyou.wangcong@gmail.com \
    /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;
as well as URLs for NNTP newsgroup(s).