bug-gnulib
[Top][All Lists]
Advanced

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

Re: bug#57129: 29.0.50; Improve behavior of conditionals in Eshell


From: Paul Eggert
Subject: Re: bug#57129: 29.0.50; Improve behavior of conditionals in Eshell
Date: Tue, 16 Aug 2022 09:54:25 -0700
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Thunderbird/91.11.0

On 8/16/22 09:25, Eli Zaretskii wrote:
The programmer didn't
expect that because it is natural to expect each call to a function
that creates a temporary file to create a file under a new name, not
reuse the same name.

Regardless of whether the programmer expects a random name or a predictable-but-unique name, there are only a finite number of names to choose from so the programmer must take into account the possibility that the chosen name clashes with names that the programmer would prefer not to be chosen.

This means an Emacs patch such as [1] is needed regardless of whether Gnulib's gen_tempname is changed to be more random than it is. Although it's true that the bug fixed by [1] is less likely if gen_tempname generates more-random names, the bug can occur no matter what we do about gen_tempname.

[1] https://debbugs.gnu.org/cgi/bugreport.cgi?filename=0001-Don-t-create-temp-file-with-same-name-as-visited.patch;bug=57129;msg=59;att=2



reply via email to

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