[fpc-pascal] GetTempFileName in Linux

Jonas Maebe jonas.maebe at elis.ugent.be
Tue Oct 5 17:41:56 CEST 2010


On 05 Oct 2010, at 17:38, Michael Van Canneyt wrote:

> On Tue, 5 Oct 2010, Leonardo M. Ramé wrote:
> 
>> Hi, if I run this program from command line in Linux, I allways get the same result, "/tmp/TMP00000.tmp". Shouldn't it return a different file name each time it's executed?. 
>> How can I get different file names?
> 
> By actually creating the file. GetTempFileName does not create a file, but
> does check whether the filename exists.

What is the use of that? Between the check and creating the file, some other process may already have created it.


Jonas


More information about the fpc-pascal mailing list