mirror of
https://github.com/python/cpython.git
synced 2025-09-25 09:50:37 +00:00
Closes #16588: Silence unused-but-set warnings in Python/thread_pthread.h
This commit is contained in:
parent
8c7c697e49
commit
7ddd9c21da
2 changed files with 5 additions and 0 deletions
|
@ -284,6 +284,7 @@ PyThread_free_lock(PyThread_type_lock lock)
|
|||
sem_t *thelock = (sem_t *)lock;
|
||||
int status, error = 0;
|
||||
|
||||
(void) error; /* silence unused-but-set-variable warning */
|
||||
dprintf(("PyThread_free_lock(%p) called\n", lock));
|
||||
|
||||
if (!thelock)
|
||||
|
@ -314,6 +315,7 @@ PyThread_acquire_lock(PyThread_type_lock lock, int waitflag)
|
|||
sem_t *thelock = (sem_t *)lock;
|
||||
int status, error = 0;
|
||||
|
||||
(void) error; /* silence unused-but-set-variable warning */
|
||||
dprintf(("PyThread_acquire_lock(%p, %d) called\n", lock, waitflag));
|
||||
|
||||
do {
|
||||
|
@ -341,6 +343,7 @@ PyThread_release_lock(PyThread_type_lock lock)
|
|||
sem_t *thelock = (sem_t *)lock;
|
||||
int status, error = 0;
|
||||
|
||||
(void) error; /* silence unused-but-set-variable warning */
|
||||
dprintf(("PyThread_release_lock(%p) called\n", lock));
|
||||
|
||||
status = sem_post(thelock);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue