[prev in list] [next in list] [prev in thread] [next in thread] 

List:       ms-cryptoapi
Subject:    Re: WINCRYPT.H from C++
From:       "Villa, Andrea" <Andrea_Villa () NAI ! COM>
Date:       1999-01-28 18:22:40
[Download RAW message or body]


extern "C" keeps the expored functions from being mangled the
C++ way, so a C (and C++) program can dynamically link to
those exports.

a C program can not call a function in a DLL that is mangled for
C++

/andy

> -----Original Message-----
> From: Kain, Michael T [SMTP:Michael.Kain@UNISYS.COM]
> Sent: Wednesday, January 27, 1999 3:03 PM
> To:   CryptoAPI@DISCUSS.MICROSOFT.COM
> Subject:      WINCRYPT.H from C++
>
> I'm having some problems picking up some definitions that are
> defined in wincrypt.h from a C++ program (VC++ 4.2 running
> on NT 4.0 SP3).
>
> The #define and structure definitions in wincrypt.h are enclosed in an
> extern "C" {
> }
>
> If the variable __cplusplus is defined.  Why?  Why is there
> a difference?  How do I pick up the definitions?
>
> Mike Kain
> Open Networking Group, Networking and I/O Channels
> Unisys Corporation, Malvern, PA (Michael.Kain@Unisys.com)
>
> Adjunct Professor, Math & Computer Science Department
> Drexel University, Philadelphia, PA (mkain@mcs.drexel.edu)
>
> ----------------------------------------------------------------
> Users Guide http://www.microsoft.com/workshop/essentials/mail.asp
> contains important info including how to unsubscribe.  Save time, search
> the archives at http://discuss.microsoft.com/archives/index.html

----------------------------------------------------------------
Users Guide http://www.microsoft.com/workshop/essentials/mail.asp
contains important info including how to unsubscribe.  Save time, search
the archives at http://discuss.microsoft.com/archives/index.html

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic