mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-20 11:40:18 +02:00
Type-check the OWNER argument of `lock-mutex'.
* libguile/threads.c (scm_lock_mutex_timed): Type-check OWNER.
This commit is contained in:
parent
4bc95fccad
commit
97ec95b728
1 changed files with 3 additions and 0 deletions
|
@ -1460,6 +1460,9 @@ SCM_DEFINE (scm_lock_mutex_timed, "lock-mutex", 1, 2, 0,
|
|||
waittime = &cwaittime;
|
||||
}
|
||||
|
||||
if (!SCM_UNBNDP (owner) && !scm_is_false (owner))
|
||||
SCM_VALIDATE_THREAD (3, owner);
|
||||
|
||||
exception = fat_mutex_lock (m, waittime, owner, &ret);
|
||||
if (!scm_is_false (exception))
|
||||
scm_ithrow (SCM_CAR (exception), scm_list_1 (SCM_CDR (exception)), 1);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue