From 75bfe825fc4018173b0d7a3c4029094edb52d93a Mon Sep 17 00:00:00 2001 From: Dave Reisner Date: Wed, 15 Dec 2010 19:57:31 -0500 Subject: add curl to alpm initialization and teardown routines Signed-off-by: Dave Reisner --- lib/libalpm/alpm.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'lib/libalpm/alpm.c') diff --git a/lib/libalpm/alpm.c b/lib/libalpm/alpm.c index 4f95832d..e5b47444 100644 --- a/lib/libalpm/alpm.c +++ b/lib/libalpm/alpm.c @@ -23,6 +23,10 @@ #include "config.h" +#ifdef HAVE_LIBCURL +#include +#endif + /* connection caching setup */ #ifdef HAVE_LIBFETCH #include @@ -69,6 +73,11 @@ int SYMEXPORT alpm_initialize(void) fetchConnectionCacheInit(5, 1); #endif +#ifdef HAVE_LIBCURL + curl_global_init(CURL_GLOBAL_SSL); + handle->curl = curl_easy_init(); +#endif + return(0); } @@ -92,6 +101,10 @@ int SYMEXPORT alpm_release(void) fetchConnectionCacheClose(); #endif +#ifdef HAVE_LIBCURL + curl_global_cleanup(); +#endif + return(0); } -- cgit v1.2.3-24-g4f1b From f2eac18a6ec62db3ec53744064e05416024c1b30 Mon Sep 17 00:00:00 2001 From: Dave Reisner Date: Tue, 8 Feb 2011 21:05:53 -0500 Subject: Remove all traces of libfetch Signed-off-by: Dave Reisner --- lib/libalpm/alpm.c | 13 ------------- 1 file changed, 13 deletions(-) (limited to 'lib/libalpm/alpm.c') diff --git a/lib/libalpm/alpm.c b/lib/libalpm/alpm.c index e5b47444..db2a63de 100644 --- a/lib/libalpm/alpm.c +++ b/lib/libalpm/alpm.c @@ -27,11 +27,6 @@ #include #endif -/* connection caching setup */ -#ifdef HAVE_LIBFETCH -#include -#endif - /* libalpm */ #include "alpm.h" #include "alpm_list.h" @@ -69,10 +64,6 @@ int SYMEXPORT alpm_initialize(void) bindtextdomain("libalpm", LOCALEDIR); #endif -#ifdef HAVE_LIBFETCH - fetchConnectionCacheInit(5, 1); -#endif - #ifdef HAVE_LIBCURL curl_global_init(CURL_GLOBAL_SSL); handle->curl = curl_easy_init(); @@ -97,10 +88,6 @@ int SYMEXPORT alpm_release(void) _alpm_handle_free(handle); handle = NULL; -#ifdef HAVE_LIBFETCH - fetchConnectionCacheClose(); -#endif - #ifdef HAVE_LIBCURL curl_global_cleanup(); #endif -- cgit v1.2.3-24-g4f1b