[Python-checkins] cpython (merge 3.3 -> default): Issue #16588: Silence unused-but-set warnings in Python/thread_pthread.h
christian.heimes
python-checkins at python.org
Sun Dec 2 08:39:47 CET 2012
http://hg.python.org/cpython/rev/33b070ef0bad
changeset: 80679:33b070ef0bad
parent: 80676:58d831412e67
parent: 80678:470785a9fdd5
user: Christian Heimes <christian at cheimes.de>
date: Sun Dec 02 08:39:23 2012 +0100
summary:
Issue #16588: Silence unused-but-set warnings in Python/thread_pthread.h
files:
Misc/NEWS | 2 ++
Python/thread_pthread.h | 3 +++
2 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/Misc/NEWS b/Misc/NEWS
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -10,6 +10,8 @@
Core and Builtins
-----------------
+- Issue #16588: Silence unused-but-set warnings in Python/thread_pthread
+
- Issue #16592: stringlib_bytes_join doesn't raise MemoryError on allocation
failure.
diff --git a/Python/thread_pthread.h b/Python/thread_pthread.h
--- a/Python/thread_pthread.h
+++ b/Python/thread_pthread.h
@@ -303,6 +303,7 @@
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)
@@ -335,6 +336,7 @@
int status, error = 0;
struct timespec ts;
+ (void) error; /* silence unused-but-set-variable warning */
dprintf(("PyThread_acquire_lock_timed(%p, %lld, %d) called\n",
lock, microseconds, intr_flag));
@@ -385,6 +387,7 @@
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);
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list