coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: How to make a temp fifo?


From: Eric Blake
Subject: Re: How to make a temp fifo?
Date: Fri, 11 Nov 2011 11:38:32 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:7.0.1) Gecko/20110930 Thunderbird/7.0.1

On 11/11/2011 11:36 AM, Peng Yu wrote:
> Hi,
> 
> I'm wondering if there is a way to make a temp fifo. I could use the
> following to generate a temp fifo. But I'm wondering what is the
> safest way to generate a temp fifo.

dir=$(mktemp -d)
file=$dir/file
mkfifo $file

<do something>

rm -rf $dir

This discussion has come up before in the mailing lists; search the
archives.

-- 
Eric Blake   address@hidden    +1-801-349-2682
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]