Bug 181785 - [patch] Man page for tmpfile() is inconsistent
Summary: [patch] Man page for tmpfile() is inconsistent
Status: Closed FIXED
Alias: None
Product: Documentation
Classification: Unclassified
Component: Manual Pages (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-bugs (Nobody)
URL:
Keywords: patch
Depends on:
Blocks:
 
Reported: 2013-09-03 19:20 UTC by Kevin P. Neal
Modified: 2020-08-14 06:50 UTC (History)
2 users (show)

See Also:


Attachments
file.diff (349 bytes, patch)
2013-09-03 19:20 UTC, Kevin P. Neal
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Kevin P. Neal 2013-09-03 19:20:01 UTC
The manual page for tmpfile(), which is shared with tmpnam() and tempnam(),
describes how tmpfile() respects the TMPDIR environment variable. It then
later on says:

     TMPDIR  [tempnam() only] If set, the directory in which the temporary
             file is stored.  TMPDIR is ignored for processes for which
             issetugid(2) is true.

Well, if tmpfile() respects TMPDIR then why does it say it doesn't?
Especially since it already went to the trouble of saying it did.

How-To-Repeat: 
man tmpfile

Scratch head and then check source.

While I'm on the subject, it may be a good idea to change the description
to state that at least some of these functions are part of POSIX. Or,
perhaps just remove the line that states:

     These interfaces are provided from System V and ANSI compatibility only.
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2013-09-03 23:51:22 UTC
Responsible Changed
From-To: freebsd-bugs->freebsd-doc

reclassify.
Comment 2 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 08:00:59 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped
Comment 3 commit-hook freebsd_committer 2020-08-07 16:20:49 UTC
A commit references this bug:

Author: gbe
Date: Fri Aug  7 16:20:07 UTC 2020
New revision: 364029
URL: https://svnweb.freebsd.org/changeset/base/364029

Log:
  tmpnam(3): Also mention tmpfile in the ENVIRONMENT section

  PR:		181785
  Submitted by:	Kevin P. Neal <kpneal atpobox dot com>
  MFC after:	1 week

Changes:
  head/lib/libc/stdio/tmpnam.3
Comment 4 Gordon Bergling freebsd_committer 2020-08-07 16:21:09 UTC
Committed, thanks for the patch!
Comment 5 commit-hook freebsd_committer 2020-08-14 06:48:50 UTC
A commit references this bug:

Author: gbe
Date: Fri Aug 14 06:48:30 UTC 2020
New revision: 364231
URL: https://svnweb.freebsd.org/changeset/base/364231

Log:
  MFC r364029: tmpnam(3): Also mention tmpfile in the ENVIRONMENT section

  PR:		181785
  Submitted by:	Kevin P. Neal <kpneal at pobox dot com>

Changes:
_U  stable/12/
  stable/12/lib/libc/stdio/tmpnam.3