From b7b6e3c5859bb8807385d5791e6a6bb3d22c42f8 Mon Sep 17 00:00:00 2001 From: Naruto TAKAHASHI Date: Tue, 27 Jul 2010 10:29:58 +0000 Subject: [PATCH] From: Naruto TAKAHASHI Subject: [E-devel] [PATCH] ecore_con_url_httpauth_set() Hi all, I attach a tiny Patch for ecore_con_url_httpauth_set(). CURLOPT_USERNAME and CURLOPT_PASSWORD is declared in enum, so those options isn't able to be used #ifdef macro's argument. This patch checks that LIBCURLVERSION_NUM is 0x071301(v7.19.1) and over. Because CURLOPT_USERNAME and CURLOPT_PASSWORD was added at 7.19.1. thanks to confirm this patch. SVN revision: 50539 --- legacy/ecore/src/lib/ecore_con/ecore_con_url.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/legacy/ecore/src/lib/ecore_con/ecore_con_url.c b/legacy/ecore/src/lib/ecore_con/ecore_con_url.c index 3aad020e92..2736328644 100644 --- a/legacy/ecore/src/lib/ecore_con/ecore_con_url.c +++ b/legacy/ecore/src/lib/ecore_con/ecore_con_url.c @@ -739,8 +739,7 @@ ecore_con_url_httpauth_set(Ecore_Con_Url *url_con, const char *username, return 0; } -# ifdef CURLOPT_USERNAME -# ifdef CURLOPT_PASSWORD +# if LIBCURL_VERSION_NUM >= 0x071301 if ((username != NULL) && (password != NULL)) { if (safe) @@ -754,7 +753,6 @@ ecore_con_url_httpauth_set(Ecore_Con_Url *url_con, const char *username, return 1; } -# endif # endif #endif return 0;