Craig Rodrigues wrote:

return static_cast<unsigned long>(pthread_self());

pthread_self() returns something of type pthread_t.
This code works under Linux, because pthread_t is mapped to an integer value.

However, on FreeBSD, pthread_t is a pointer to struct pthread, so this
code does not compile:

OpenSSLPluginI.cpp: In function `long unsigned int IceSSL::idFunction()':
OpenSSLPluginI.cpp:153: invalid static_cast from type `pthread*' to type `long
   unsigned int'


Is there a way to implement the id_function() for OpenSSL so that it works portably across FreeBSD and Linux?

return (unsigned long)(void *)(pthread_self());



-- Lev Walkin [EMAIL PROTECTED]


To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-current" in the body of the message

Reply via email to