Subject: bug#75938: Sv: bug#75938: 31.0.50; Temporary file-names overflowing MAX_PATH characters

From: Paul Eggert <[email-masked]>
Date: Thu, 30 Jan 2025 20:14:56 -0800

On 1/30/25 18:01, arthur miller wrote:
> (make-temp-name (* 1024 1024 1024) ?a) <- asks for 1 gig of chars
> 
> After trying to execute that, I get message that Emacs has recovered
> from the C stack overflow.

I assume you mean:

   (make-temp-name (make-string (* 1024 1024 1024) ?a))

and I don't observe the problem on bleeding-edge Emacs (commit 
a5965217fc1d7b56df60f8e798edd48ae52c8624) when built on Fedora 41 
x86-64. There is no C stack overflow, and make-temp-name signals 
(file-error "Creating file name with prefix" "File name too long" 
"aaa...") as expected.

If you're getting a C stack overflow on bleeding-edge Emacs, it might be 
helpful to see exactly why. This would likely require running Emacs 
under a debugger.