From 3bc8c28ce3b7f06203842abbf8a8c5e0d21886e9 Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Sun, 11 Oct 2009 14:04:28 -0500 Subject: Add missing get_usedelta() method Signed-off-by: Dan McGee --- lib/libalpm/alpm.h | 1 + lib/libalpm/handle.c | 9 +++++++++ 2 files changed, 10 insertions(+) (limited to 'lib') diff --git a/lib/libalpm/alpm.h b/lib/libalpm/alpm.h index 8033e4d8..ae2dc1fc 100644 --- a/lib/libalpm/alpm.h +++ b/lib/libalpm/alpm.h @@ -154,6 +154,7 @@ int alpm_option_remove_ignoregrp(const char *grp); const char *alpm_option_get_arch(); void alpm_option_set_arch(const char *arch); +int alpm_option_get_usedelta(); void alpm_option_set_usedelta(int usedelta); pmdb_t *alpm_option_get_localdb(); diff --git a/lib/libalpm/handle.c b/lib/libalpm/handle.c index a503baea..5cbf363a 100644 --- a/lib/libalpm/handle.c +++ b/lib/libalpm/handle.c @@ -223,6 +223,15 @@ const char SYMEXPORT *alpm_option_get_arch() return handle->arch; } +int SYMEXPORT alpm_option_get_usedelta() +{ + if (handle == NULL) { + pm_errno = PM_ERR_HANDLE_NULL; + return -1; + } + return handle->usedelta; +} + pmdb_t SYMEXPORT *alpm_option_get_localdb() { if (handle == NULL) { -- cgit v1.2.3-70-g09d2