On 2/13/07, Ben Pfaff <[EMAIL PROTECTED]> wrote:
I really think that we can use the gnulib version of mkstemp, but
surely someone else has encountered this and can perhaps provide
guidance.

Yes. That would probably be better than linking against libiberty

Another option would be to add a gnulib module for tmpfile that
replaces it with a non-broken one.

From man tmpfile: "The  standard  does not specify the directory that
tmpfile() will use. Glibc will try the path prefix P_tmpdir defined in
<stdio.h>, and if that fails the directory /tmp."

Ironically, this is not compatible with the GNU coding standard which
states that you should fisrt check the "TMPDIR" environment variable
(unless perhaps the suid or sgid bit is set). With the patch at
 http://lists.gnu.org/archive/html/pspp-dev/2007-02/txtIdtmRJpUxd.txt
we are on the way to implementing a GNU coding standard compliant
version of tmpdir(). I suggest that we create a "gnu_tmpfile()"
function and exclusively call that. Perhaps gnu_tmpfile() should also
be put in gnulib?

--
John C. McCabe-Dansted
PhD Student
University of Western Australia


_______________________________________________
pspp-dev mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/pspp-dev

Reply via email to