[Dune] Dune on Windows MinGW
Martin Nolte
nolte at mathematik.uni-freiburg.de
Wed May 4 16:21:24 CEST 2011
Hi Olaf,
thanks a lot for the patch. I just committed a slight variant (still having
the method and including correct headers). We should notice that the man-pages
decourage the use of this function though (maybe due to not opening the file).
Best,
Martin
On 05/04/2011 03:28 PM, Dr. Olaf Ippisch wrote:
> Hi Oliver and Others,
>
> here is the patch. It uses the Posix function tmpnam, which generates
> the name of a temporary file. The differences between tmpnam and the
> non-Posix function mkstemp used in the original function
> temporaryFileName() are:
>
> - the form of the file name can not be influenced, when calling tmpnam.
> It just generates some unique filename.
>
> - mkstemp also makes sure that the file is directly opened such that it
> can not happen that another process opens a file with the same name in
> the time between the call to the name-generating function and the call
> to fopen. However, as the file is afterwards closed again in
> temporaryFileName() and just the name (and not the file pointer)
> returned, this advantage is lost anyhow.
>
> I hope that this is acceptable and think this should be a sufficient
> replacement (which also reduces the amount of code).
>
> Regards,
> Olaf
>
>
>
>
>
> _______________________________________________
> Dune mailing list
> Dune at dune-project.org
> http://lists.dune-project.org/mailman/listinfo/dune
--
Martin Nolte <nolte at mathematik.uni-freiburg.de>
Universität Freiburg phone: +49-761-203-5630
Abteilung für angewandte Mathematik fax: +49-761-203-5632
Hermann-Herder-Straße 10
79104 Freiburg, Germany
More information about the Dune
mailing list