summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJason Woodward2010-09-12 10:51:42 -0400
committerJason Woodward2010-09-12 10:51:42 -0400
commitd5b229d22002784973a0cfcf5ae14e35064ebdc5 (patch)
tree7d8e16a8a93f051c7e5ffad2086d07893412c87f /src
parent69b56c542ce7b1d65b6da29a254481e5724fdb6f (diff)
downloadslapt-get-d5b229d22002784973a0cfcf5ae14e35064ebdc5.tar.gz
added slapt_download_data to public API
Diffstat (limited to 'src')
-rw-r--r--src/curl.c2
-rw-r--r--src/curl.h6
2 files changed, 7 insertions, 1 deletions
diff --git a/src/curl.c b/src/curl.c
index 2a407e2..8b9b5a0 100644
--- a/src/curl.c
+++ b/src/curl.c
@@ -25,7 +25,7 @@ struct head_data_t {
size_t size;
};
-static int slapt_download_data(FILE *fh,const char *url,size_t bytes,long *filetime,
+int slapt_download_data(FILE *fh,const char *url,size_t bytes,long *filetime,
const slapt_rc_config *global_config)
{
CURL *ch = NULL;
diff --git a/src/curl.h b/src/curl.h
index 44256c2..b6643cc 100644
--- a/src/curl.h
+++ b/src/curl.h
@@ -1,5 +1,11 @@
/*
+ download data to file
+ returns curl code
+*/
+int slapt_download_data(FILE *, const char *, size_t, long *, const slapt_rc_config *);
+
+/*
retrieves the head data for the url, returns (char *) or NULL on error
*/
char *slapt_head_request(const char *url);