This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author David.Edelsohn
Recipients David.Edelsohn
Date 2013-06-18.13:58:40
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1371563921.33.0.845649909744.issue18256@psf.upfronthosting.co.za>
In-reply-to
Content
Recent releases of AIX do not need to call pthread_init(). The function is provided in libpthread.a for backward compatibility, but not declared in any header. This patch adds a declaration, or it can be removed completely because AIX 4.x no longer is supported.

The patch also adds uses of "error" to two functions to silence warnings, in a similar manner to other functions in the file.

diff -r f6f70f1ab124 Python/thread_pthread.h
--- a/Python/thread_pthread.h   Mon Jun 17 22:02:14 2013 +0200
+++ b/Python/thread_pthread.h   Tue Jun 18 11:54:50 2013 -0700
@@ -170,6 +170,7 @@
 PyThread__init_thread(void)
 {
 #if defined(_AIX) && defined(__GNUC__)
+    extern void pthread_init(void);
     pthread_init();
 #endif
 }
@@ -444,6 +445,7 @@
     pthread_lock *thelock = (pthread_lock *)lock;
     int status, error = 0;
 
+    (void) error; /* silence unused-but-set-variable warning */
     dprintf(("PyThread_free_lock(%p) called\n", lock));
 
     /* some pthread-like implementations tie the mutex to the cond
@@ -530,6 +532,7 @@
     pthread_lock *thelock = (pthread_lock *)lock;
     int status, error = 0;
 
+    (void) error; /* silence unused-but-set-variable warning */
     dprintf(("PyThread_release_lock(%p) called\n", lock));
 
     status = pthread_mutex_lock( &thelock->mut );
History
Date User Action Args
2013-06-18 13:58:41David.Edelsohnsetrecipients: + David.Edelsohn
2013-06-18 13:58:41David.Edelsohnsetmessageid: <1371563921.33.0.845649909744.issue18256@psf.upfronthosting.co.za>
2013-06-18 13:58:41David.Edelsohnlinkissue18256 messages
2013-06-18 13:58:40David.Edelsohncreate