diff options
| author | Paul Eggert | 2016-12-22 10:13:46 -0800 |
|---|---|---|
| committer | Paul Eggert | 2016-12-22 10:14:11 -0800 |
| commit | 73349822cbd6e50526eda9c75453584d73dfca83 (patch) | |
| tree | 444c07a3fbaaf3b2b02e1a08a18bad5bab7bbef0 /src/thread.c | |
| parent | b10bd71987cdeb753c106145d6270a359505359c (diff) | |
| download | emacs-73349822cbd6e50526eda9c75453584d73dfca83.tar.gz emacs-73349822cbd6e50526eda9c75453584d73dfca83.zip | |
; Spelling fixes
Diffstat (limited to 'src/thread.c')
| -rw-r--r-- | src/thread.c | 11 |
1 files changed, 5 insertions, 6 deletions
diff --git a/src/thread.c b/src/thread.c index 6966df31d37..9613d1435f7 100644 --- a/src/thread.c +++ b/src/thread.c | |||
| @@ -257,7 +257,7 @@ If the current thread already owns MUTEX, increment the count and | |||
| 257 | return. | 257 | return. |
| 258 | Otherwise, if no thread owns MUTEX, make the current thread own it. | 258 | Otherwise, if no thread owns MUTEX, make the current thread own it. |
| 259 | Otherwise, block until MUTEX is available, or until the current thread | 259 | Otherwise, block until MUTEX is available, or until the current thread |
| 260 | is signalled using `thread-signal'. | 260 | is signaled using `thread-signal'. |
| 261 | Note that calls to `mutex-lock' and `mutex-unlock' must be paired. */) | 261 | Note that calls to `mutex-lock' and `mutex-unlock' must be paired. */) |
| 262 | (Lisp_Object mutex) | 262 | (Lisp_Object mutex) |
| 263 | { | 263 | { |
| @@ -363,8 +363,7 @@ condition_wait_callback (void *arg) | |||
| 363 | XSETCONDVAR (cond, cvar); | 363 | XSETCONDVAR (cond, cvar); |
| 364 | self->event_object = cond; | 364 | self->event_object = cond; |
| 365 | saved_count = lisp_mutex_unlock_for_wait (&mutex->mutex); | 365 | saved_count = lisp_mutex_unlock_for_wait (&mutex->mutex); |
| 366 | /* If we were signalled while unlocking, we skip the wait, but we | 366 | /* If signaled while unlocking, skip the wait but reacquire the lock. */ |
| 367 | still must reacquire our lock. */ | ||
| 368 | if (NILP (self->error_symbol)) | 367 | if (NILP (self->error_symbol)) |
| 369 | { | 368 | { |
| 370 | self->wait_condvar = &cvar->cond; | 369 | self->wait_condvar = &cvar->cond; |
| @@ -384,7 +383,7 @@ The mutex associated with COND must be held when this is called. | |||
| 384 | It is an error if it is not held. | 383 | It is an error if it is not held. |
| 385 | 384 | ||
| 386 | This releases the mutex and waits for COND to be notified or for | 385 | This releases the mutex and waits for COND to be notified or for |
| 387 | this thread to be signalled with `thread-signal'. When | 386 | this thread to be signaled with `thread-signal'. When |
| 388 | `condition-wait' returns, COND's mutex will again be locked by | 387 | `condition-wait' returns, COND's mutex will again be locked by |
| 389 | this thread. */) | 388 | this thread. */) |
| 390 | (Lisp_Object cond) | 389 | (Lisp_Object cond) |
| @@ -404,7 +403,7 @@ this thread. */) | |||
| 404 | return Qnil; | 403 | return Qnil; |
| 405 | } | 404 | } |
| 406 | 405 | ||
| 407 | /* Used to communicate argumnets to condition_notify_callback. */ | 406 | /* Used to communicate arguments to condition_notify_callback. */ |
| 408 | struct notify_args | 407 | struct notify_args |
| 409 | { | 408 | { |
| 410 | struct Lisp_CondVar *cvar; | 409 | struct Lisp_CondVar *cvar; |
| @@ -814,7 +813,7 @@ or `thread-join' in the target thread. */) | |||
| 814 | if (tstate == current_thread) | 813 | if (tstate == current_thread) |
| 815 | Fsignal (error_symbol, data); | 814 | Fsignal (error_symbol, data); |
| 816 | 815 | ||
| 817 | /* What to do if thread is already signalled? */ | 816 | /* What to do if thread is already signaled? */ |
| 818 | /* What if error_symbol is Qnil? */ | 817 | /* What if error_symbol is Qnil? */ |
| 819 | tstate->error_symbol = error_symbol; | 818 | tstate->error_symbol = error_symbol; |
| 820 | tstate->error_data = data; | 819 | tstate->error_data = data; |