diff --git a/src/thread.c b/src/thread.c index 83f25e8d462..8fa43dd57f2 100644 --- a/src/thread.c +++ b/src/thread.c @@ -185,6 +185,9 @@ informational only. */) struct Lisp_Mutex *mutex; Lisp_Object result; + if (!NILP (name)) + CHECK_STRING (name); + mutex = ALLOCATE_PSEUDOVECTOR (struct Lisp_Mutex, mutex, PVEC_MUTEX); memset ((char *) mutex + offsetof (struct Lisp_Mutex, mutex), 0, sizeof (struct Lisp_Mutex) - offsetof (struct Lisp_Mutex,