From: Petr Baudis <pasky-AlSwsSmVLrQ@public.gmane.org>
To: Jeff Mahovsky <Jeff.Mahovsky-hCDZnVt6e3JSwrhanM7KvQ@public.gmane.org>
Cc: mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org,
linux-man-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: stat(2) does not indicate behavior with NULL filename arg, man pages 3.24
Date: Tue, 11 May 2010 03:46:03 +0200 [thread overview]
Message-ID: <20100511014603.GE16800@machine.or.cz> (raw)
In-Reply-To: <4BCF4B3A.8020909-hCDZnVt6e3JSwrhanM7KvQ@public.gmane.org>
On Wed, Apr 21, 2010 at 12:00:10PM -0700, Jeff Mahovsky wrote:
> The stat(2) manpage does not indicate the behavior of the stat()
> function when the filename is a NULL pointer. Does stat() return an
> error or is the behavior undefined?
I think it is generally not safe to rely on proper handling of such NULL
pointers unless it is explicitly specified that they are handled
correctly. I think e.g. glibc will happily peek at the stat()'s filename
if you compile with -fbounded-pointers.
--
Petr "Pasky" Baudis
When I feel like exercising, I just lie down until the feeling
goes away. -- xed_over
--
To unsubscribe from this list: send the line "unsubscribe linux-man" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
next prev parent reply other threads:[~2010-05-11 1:46 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-21 19:00 stat(2) does not indicate behavior with NULL filename arg, man pages 3.24 Jeff Mahovsky
[not found] ` <4BCF4B3A.8020909-hCDZnVt6e3JSwrhanM7KvQ@public.gmane.org>
2010-05-11 1:46 ` Petr Baudis [this message]
2010-05-24 5:23 ` Michael Kerrisk
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=20100511014603.GE16800@machine.or.cz \
--to=pasky-alswssmvlrq@public.gmane.org \
--cc=Jeff.Mahovsky-hCDZnVt6e3JSwrhanM7KvQ@public.gmane.org \
--cc=linux-man-u79uwXL29TY76Z2rM5mHXA@public.gmane.org \
--cc=mtk.manpages-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.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.