[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Sheflug] Unique temporary filename
On Wed, 15 May 2002, David Morris wrote:
> Can anyone suggest a quick way of generating a unique temporary file name in
> PERL? I've written a quick mail mime scanner (using reformime) for our
> server to email the system admin if it spots any wierd mime attachments in
> messages, but it clearly needs to support concurrent deliveries, so a
> hardcoded filename won't work.
>
> Alternatively, I'll have to construct something using date and time and
> process number. Would a simple concatenation of those work?
>
> Suggestions on the back of a postcard...
mktemp ??
>
>
> --
> David Morris
> IT Manager, ALLVAC Ltd, Sheffield, UK
> work: david [at] allvac.co.uk
> home: david [at] brassedoff.net http://www.davidm.demon.co.uk
>
> ___________________________________________________________________
>
> Sheffield Linux User's Group -
> http://www.sheflug.co.uk/mailfaq.html
>
> GNU the choice of a complete generation.
>
--
uklinux.net - The ISP of choice for the discerning Linux user.
___________________________________________________________________
Sheffield Linux User's Group -
http://www.sheflug.co.uk/mailfaq.html
GNU the choice of a complete generation.