Haxx ad

curl's project page on


cURL > Mailing List > Monthly Index > Single Mail

curlpp mailing list Archives

[cURLpp] [solved] VS C++ compilation errors

From: Peteris Krumins [Newsgroups] <>
Date: Tue, 02 Aug 2005 19:19:17 +0300


 Ok, here is why it doesnt work.
 cURL.hpp "wraps" curl.h header in cURL namespace. Everything in curl.h gets
 declared in cURL namespace. curl.h also #includes time.h. So everything in time.h
 gets declared in cURL namespace as well.
 When someone #includes ctime after cURL.hpp has been included, time.h guards
 prevent it from being included in ctime again so what should have been declared
 in global namespace does not get declared there.
 And boom, errors. See the example below.

 This is very bad. As cURL.hpp is the essence of cURLpp, the whole library at the
 moment is broken.
 The only fix I see is not to "wrap" curl.h in cURL namespace. This fix breaks
 compatibility with previous versions unfortunately. :(

// Example of what happens in cURL.hpp
namespace NameSPACES {
#include <time.h>
#include <ctime>
int main(void){}


cURLpp mailing list
Received on 2005-08-02

These mail archives are generated by hypermail.

donate! Page updated November 12, 2010.
web site info

File upload with ASP.NET