cURL / Mailing Lists / curl-users / Single Mail


[ curl-Bugs-672209 ] libcurl 7.10.3 multi_* functions don't link w/ c++

From: <>
Date: Tue, 21 Jan 2003 18:21:45 -0800

Bugs item #672209, was opened at 2003-01-21 18:21
You can respond by visiting:

Category: compile or build problem
Group: portability problem
Status: Open
Resolution: None
Priority: 5
Submitted By: Nobody/Anonymous (nobody)
Assigned to: Daniel Stenberg (bagder)
Summary: libcurl 7.10.3 multi_* functions don't link w/ c++

Initial Comment:
Using the multi_* C functions within my C++ classes
generated link errors until I added an
extern "C" {}
block to multi.h. I imagine that this will affect anyone trying
to use the C multi interface from a C++ program, but am
unable to test against anything other than my own
application and curl itself.

Here's the diff with my changes that fix the problem:

< #ifdef __cplusplus
< extern "C" {
< #endif
< #ifdef __cplusplus
< }
< #endif

my compiler (Linux):
$ g++ -v
Reading specs from /usr/lib/gcc-lib/i386-linux/2.95.4/specs
gcc version 2.95.4 20011002 (Debian prerelease)

Ian Wilkes


You can respond by visiting:

This email is sponsored by: Scholarships for Techies!
Can't afford IT training? All 2003 ictp students receive scholarships.
Get hands-on training in Microsoft, Cisco, Sun, Linux/UNIX, and more.
Received on 2003-01-22