gnash-commit
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Gnash-commit] gnash libbase/curl_adapter.cpp ChangeLog


From: Martin Guy
Subject: [Gnash-commit] gnash libbase/curl_adapter.cpp ChangeLog
Date: Mon, 09 Jul 2007 07:31:05 +0000

CVSROOT:        /sources/gnash
Module name:    gnash
Changes by:     Martin Guy <martinwguy> 07/07/09 07:31:05

Modified files:
        libbase        : curl_adapter.cpp 
        .              : ChangeLog 

Log message:
                * libbase/curl_adapter.cpp: Workarounds for older versions of 
curl

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/gnash/libbase/curl_adapter.cpp?cvsroot=gnash&r1=1.37&r2=1.38
http://cvs.savannah.gnu.org/viewcvs/gnash/ChangeLog?cvsroot=gnash&r1=1.3686&r2=1.3687

Patches:
Index: libbase/curl_adapter.cpp
===================================================================
RCS file: /sources/gnash/gnash/libbase/curl_adapter.cpp,v
retrieving revision 1.37
retrieving revision 1.38
diff -u -b -r1.37 -r1.38
--- libbase/curl_adapter.cpp    1 Jul 2007 10:54:07 -0000       1.37
+++ libbase/curl_adapter.cpp    9 Jul 2007 07:31:05 -0000       1.38
@@ -17,7 +17,7 @@
 // Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA
 //
 
-/* $Id: curl_adapter.cpp,v 1.37 2007/07/01 10:54:07 bjacques Exp $ */
+/* $Id: curl_adapter.cpp,v 1.38 2007/07/09 07:31:05 martinwguy Exp $ */
 
 #ifdef HAVE_CONFIG_H
 #include "config.h"
@@ -75,6 +75,36 @@
 
 #include <curl/curl.h>
 
+// Adapt to older versions of libcurl.
+//
+// In 7.10.7 and before, CURLINFO_RESPONSE_CODE was called CURLINFO_HTTP_CODE
+//
+#if LIBCURL_VERSION_NUM <= 0x070a07
+# define CURLINFO_RESPONSE_CODE CURLINFO_HTTP_CODE
+#endif
+//
+// curl_multi_strerror() and curl_easy_strerror() came in at 7.12.0
+// Just print the number and tell the user how to decode it.
+//
+#if LIBCURL_VERSION_NUM < 0x070c00
+static char curl_strerror_buf[64];
+static const char *
+curl_easy_strerror(int code)
+{
+       sprintf(curl_strerror_buf,
+               "CurlE error code %d (man libcurl-errors)", code);
+       return curl_strerror_buf;
+}
+
+static const char *
+curl_multi_strerror(int code)
+{
+       sprintf(curl_strerror_buf,
+               "CurlM error code %d (man libcurl-errors)", code);
+       return curl_strerror_buf;
+}
+#endif
+
 namespace curl_adapter
 {
 

Index: ChangeLog
===================================================================
RCS file: /sources/gnash/gnash/ChangeLog,v
retrieving revision 1.3686
retrieving revision 1.3687
diff -u -b -r1.3686 -r1.3687
--- ChangeLog   9 Jul 2007 07:26:44 -0000       1.3686
+++ ChangeLog   9 Jul 2007 07:31:05 -0000       1.3687
@@ -1,6 +1,7 @@
 2007-07-09 Martin Guy <address@hidden>
 
        * gui/gtk_cairo.h: FIx compiler warning about unused params
+       * libbase/curl_adapter.cpp: Workarounds for older versions of curl
 
 2007-07-08 Sandro Santilli <address@hidden>
 




reply via email to

[Prev in Thread] Current Thread [Next in Thread]