From 79cbce60ac4a40bf11d039e9bdcd09c852ce3292 Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Mon, 19 Sep 2011 14:32:53 -0500 Subject: Remove all usages of alpm_list_getdata() from the library No need for the indirection; just access ->data instead. Signed-off-by: Dan McGee --- lib/libalpm/util.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'lib/libalpm/util.c') diff --git a/lib/libalpm/util.c b/lib/libalpm/util.c index e2f2f441..a15eb965 100644 --- a/lib/libalpm/util.c +++ b/lib/libalpm/util.c @@ -652,7 +652,7 @@ char *_alpm_filecache_find(alpm_handle_t *handle, const char *filename) /* Loop through the cache dirs until we find a matching file */ for(i = handle->cachedirs; i; i = i->next) { - snprintf(path, PATH_MAX, "%s%s", (char *)alpm_list_getdata(i), + snprintf(path, PATH_MAX, "%s%s", (char *)i->data, filename); if(stat(path, &buf) == 0 && S_ISREG(buf.st_mode)) { retpath = strdup(path); @@ -677,7 +677,7 @@ const char *_alpm_filecache_setup(alpm_handle_t *handle) /* Loop through the cache dirs until we find a usable directory */ for(i = handle->cachedirs; i; i = i->next) { - cachedir = alpm_list_getdata(i); + cachedir = i->data; if(stat(cachedir, &buf) != 0) { /* cache directory does not exist.... try creating it */ _alpm_log(handle, ALPM_LOG_WARNING, _("no %s cache exists, creating...\n"), -- cgit v1.2.3-24-g4f1b