Subject: bug#38632: 27.0.50; Emacs process name is changed permanently upon creating a named thread

From: Ihor Radchenko <[email-masked]>
Date: Mon, 16 Dec 2019 14:42:38 +0800

Observed behaviour:

When I try to create a named thread like

(make-thread (lambda () (+ 1 2)) "test-emacs-async")

the emacs process gets renamed to "test-emacs-async" even after the
thread returns. Making another thread with different name renames emacs
process again.

Expected behaviour:

Emacs process name remains unchanged.

Note: by process name, I mean "COMMAND" field in top output. 

Best,
Ihor

In GNU Emacs 27.0.50 (build 1, x86_64-pc-linux-gnu, X toolkit, cairo version 1.16.0)
 of 2019-12-16 built on yantar92-laptop
Repository revision: 7254b6346229a7b71b69f71e2d8eee113f02585a
Repository branch: master
Windowing system distributor 'The X.Org Foundation', version 11.0.12005000
System Description: Gentoo/Linux