From: Theodore Tso <tytso@mit.edu>
To: Thierry Vignaud <tvignaud@mandriva.com>
Cc: Eric Sandeen <sandeen@redhat.com>,
ext4 development <linux-ext4@vger.kernel.org>
Subject: Re: [PATCH] debugfs: don't try to fclose NULL
Date: Tue, 30 Jun 2009 12:39:56 -0400 [thread overview]
Message-ID: <20090630163956.GE7398@mit.edu> (raw)
In-Reply-To: <m2r5x1pvyg.fsf@vador.mandriva.com>
On Tue, Jun 30, 2009 at 05:44:55PM +0200, Thierry Vignaud wrote:
> Eric Sandeen <sandeen@redhat.com> writes:
>
> > do_logdump may jump to errout if fopen(out_file) fails,
> > but in that case out_file is NULL, and fclose will segfault.
>
> You should report that segfault to glibc authors too.
It would be robust for glibc to code fclose() defensively such that it
would survive a null pointer, but I don't think it's technically
required by the ANSI or POSIX spec.
- Ted
next prev parent reply other threads:[~2009-06-30 16:39 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-26 18:57 [PATCH] debugfs: don't try to fclose NULL Eric Sandeen
2009-06-29 5:07 ` Theodore Tso
2009-06-30 15:44 ` Thierry Vignaud
2009-06-30 16:39 ` Theodore Tso [this message]
2009-06-30 16:46 ` Alex Buell
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=20090630163956.GE7398@mit.edu \
--to=tytso@mit.edu \
--cc=linux-ext4@vger.kernel.org \
--cc=sandeen@redhat.com \
--cc=tvignaud@mandriva.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).