[threads] Allow resetting the name of a threadpool thread (#4350)
[mono.git] / mono / metadata / attach.c
index 13f03abf48535462f6b94fb5f912c6ab3d16183c..1f2e0fd103d93fc73768878b4f0c3181f40de996 100644 (file)
@@ -24,8 +24,6 @@
 #include <sys/stat.h>
 #include <sys/un.h>
 #include <netinet/in.h>
-#include <sys/types.h>
-#include <sys/stat.h>
 #include <fcntl.h>
 #include <inttypes.h>
 #include <pwd.h>
@@ -508,7 +506,7 @@ receiver_thread (void *arg)
                printf ("attach: Connected.\n");
 
                MonoThread *thread = mono_thread_attach (mono_get_root_domain ());
-               mono_thread_set_name_internal (thread->internal_thread, mono_string_new (mono_get_root_domain (), "Attach receiver"), TRUE, &error);
+               mono_thread_set_name_internal (thread->internal_thread, mono_string_new (mono_get_root_domain (), "Attach receiver"), TRUE, FALSE, &error);
                mono_error_assert_ok (&error);
                /* Ask the runtime to not abort this thread */
                //mono_thread_current ()->flags |= MONO_THREAD_FLAG_DONT_MANAGE;