On Wed, Jun 04, 2008 at 02:57:21PM -0400, Michael Gogins wrote: > To summarize the earlier posts in this thread: > > The Csound threading API was written to encapsulate various threading > libraries, Windows threads and POSIX threads at least. When it was > written, we used native Windows threads on Windows, and all objects > were 32 bit handles. Now, to simplify things, we are switching to use > POSIX threads on Windows also. > > On Windows, pthread_t is a structure containing a 32 bit handle and a > 32 bit reference count. That is why we are having this discussion. > > All the other pthread header types are 32 bit handles only. I know all this. So a pthread_t is 32 bits in most cases and 64 bits on Windows. So what ? It just shouldn't matter as long as you don't transfer binary data containing a pthread_t from one platform to the other. Just **don't cast it** and use pthread_t wherever the data is in fact a pthread_t. It will compile and work on all platforms that have pthread_t. That it is a 64-bit struct in some cases shouldn't matter, C functions accept a struct as a parameter and can also return a struct. BTW, on Linux pthread_t is not a pointer. It's a long int. Not that it should matter. Ciao, -- FA Laboratorio di Acustica ed Elettroacustica Parma, Italia Lascia la spina, cogli la rosa. ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://sourceforge.net/services/buy/index.php _______________________________________________ Csound-devel mailing list Csound-devel@lists.sourceforge.net