From a0490929c3ddc666d25535de73cda33923232797 Mon Sep 17 00:00:00 2001 From: Maxim Konovalov Date: Fri, 16 Mar 2007 21:46:24 +0000 Subject: [PATCH] o Add ENVIRONMENT section and mention there that TMPDIR is ignored when issetugid(3) is true. PR: docs/108346 Obtained from: OpenBSD MFC after: 1 week --- lib/libc/stdio/tmpnam.3 | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/lib/libc/stdio/tmpnam.3 b/lib/libc/stdio/tmpnam.3 index 6dd88bfff583..66652b741716 100644 --- a/lib/libc/stdio/tmpnam.3 +++ b/lib/libc/stdio/tmpnam.3 @@ -32,7 +32,7 @@ .\" @(#)tmpnam.3 8.2 (Berkeley) 11/17/93 .\" $FreeBSD$ .\" -.Dd November 17, 1993 +.Dd March 18, 2007 .Dt TMPFILE 3 .Os .Sh NAME @@ -152,6 +152,19 @@ return a pointer to a file name on success, and a .Dv NULL pointer on error. +.Sh ENVIRONMENT +.Bl -tag -width Ds +.It Ev TMPDIR +.Pf [ Fn tempnam +only] +If set, +the directory in which the temporary file is stored. +.Ev TMPDIR +is ignored for processes +for which +.Xr issetugid 2 +is true. +.El .Sh COMPATIBILITY These interfaces are provided from System V and .Tn ANSI