From b6ceb5e11ae20ede9b30979d4b54c56f84e89eaf Mon Sep 17 00:00:00 2001 From: ticktock35 Date: Mon, 15 Dec 2008 00:12:27 -0500 Subject: opkg: improve download callback handling and integrate into opkg_update_package_lists git-svn-id: http://opkg.googlecode.com/svn/trunk@86 e8e0d7a0-c8d9-11dd-a880-a1081c7ac358 --- (limited to 'libopkg/opkg_download.h') diff --git a/libopkg/opkg_download.h b/libopkg/opkg_download.h index 8b940e7..39cd9a6 100644 --- a/libopkg/opkg_download.h +++ b/libopkg/opkg_download.h @@ -21,8 +21,10 @@ #include "opkg_conf.h" typedef void (*opkg_download_progress_callback)(int percent, char *url); +typedef int (*curl_progress_func)(void *data, double t, double d, double ultotal, double ulnow); -int opkg_download(opkg_conf_t *conf, const char *src, const char *dest_file_name); + +int opkg_download(opkg_conf_t *conf, const char *src, const char *dest_file_name, curl_progress_func cb, void *data); int opkg_download_pkg(opkg_conf_t *conf, pkg_t *pkg, const char *dir); /* * Downloads file from url, installs in package database, return package name. -- cgit v0.9.1