The TAO SSLIOP implementation uses openssl, but does not compile with
some C++ compilers (including current versions of g++) due to what
appears to be problems with the DSAparams_dup() and DHparams_dup()
macros.  

This bit of code is similar to that in TAO's SSLIOP_EVP_PKEY.cpp.  It
compiles fine with gcc, but fails with with g++.  I'm using gcc 3.3.3
and openssl 0.9.7d as distributed with NetBSD 2.0RC4 and gcc 3.3 and
openssl 0.9.7b as distributed with MacOSX 10.3.6 "Panther".  I've also
reproduced the same problem with gcc 3.4.2.

Compiling this code:
    #include <openssl/asn1.h>
    #include <openssl/dsa.h>
    #include <openssl/dh.h>


    DSA *
    duplicate_dsa(DSA *dsa)
    {
            return DSAparams_dup (dsa);
    }

    DH *
    duplicate_dh(DH *dh)
    {
            return DHparams_dup (dh);
    }

Yields:
    $ g++ -O2 -c ssl.cc 
    ssl.cc: In function `DSA* duplicate_dsa(DSA*)':
    ssl.cc:9: error: invalid conversion from `int (*)()' to `int (*)(...)'
    ssl.cc:9: error: invalid conversion from `char*(*)()' to `char*(*)(...)'
    ssl.cc: In function `DH* duplicate_dh(DH*)':
    ssl.cc:15: error: invalid conversion from `int (*)()' to `int (*)(...)'
    ssl.cc:15: error: invalid conversion from `char*(*)()' to `char*(*)(...)'

I'm not quite sure whether it's TAO, g++, or openssl that's at fault,
but I'd appreciate any pointers.

    --jtc

-- 
J.T. Conklin
______________________________________________________________________
OpenSSL Project                                 http://www.openssl.org
User Support Mailing List                    [EMAIL PROTECTED]
Automated List Manager                           [EMAIL PROTECTED]

Reply via email to