creating a temporary fifo (tmpfile but for fifo)
Andrei Alexandrescu via Digitalmars-d
digitalmars-d at puremagic.com
Mon Feb 13 19:15:53 PST 2017
On 2/13/17 12:12 PM, Paul Backus wrote:
> On Sunday, 12 February 2017 at 11:47:26 UTC, Timothee Cour wrote:
>> * std.stdio.tempfile creates an (unnamed) File. How do I create a
>> fifo instead?
>> my workaround is to use tempnam but docs says it's not recommended (
> I believe the recommended function for this is mkstemp. 
>> * could we allow specifying a directory name for tmpfile?
> Yes, using mkdtemp. 
> Note that these functions are part of POSIX but not C99, and are not
> included in D's core.stdc module.
>  http://man7.org/linux/man-pages/man3/mkstemp.3.html
>  http://man7.org/linux/man-pages/man3/mkdtemp.3.html
They're declared in core.sys,posix.stdlib. -- Andrei
More information about the Digitalmars-d