summaryrefslogtreecommitdiff
path: root/lib/libalpm/be_files.c
diff options
context:
space:
mode:
authorChantry Xavier <shiningxc@gmail.com>2007-09-17 01:56:23 +0200
committerDan McGee <dan@archlinux.org>2007-09-16 20:10:18 -0500
commit046c8a6819a0533fb10434f30100f80bb960fe46 (patch)
treee73f29a2f4816c3767933fba644362d9f6a9c75f /lib/libalpm/be_files.c
parent7daf5a038d3750eacf92b819206cae6b77a73042 (diff)
downloadpacman-046c8a6819a0533fb10434f30100f80bb960fe46.tar.xz
Remove the DB consistency check from pacman and libalpm.
This reverts commit dfc85cb5f516ffbcff557522e9703c5c7d88b047 and b6f3fe6957d0206485eac98fb2120578b75d0058. This DB check is already in testdb (among others). Also testdb now uses the db path set at make time by default, so specifying the db path is optional. Signed-off-by: Chantry Xavier <shiningxc@gmail.com> Signed-off-by: Dan McGee <dan@archlinux.org>
Diffstat (limited to 'lib/libalpm/be_files.c')
-rw-r--r--lib/libalpm/be_files.c32
1 files changed, 0 insertions, 32 deletions
diff --git a/lib/libalpm/be_files.c b/lib/libalpm/be_files.c
index 3e1a2969..8998f678 100644
--- a/lib/libalpm/be_files.c
+++ b/lib/libalpm/be_files.c
@@ -62,38 +62,6 @@ int _alpm_db_install(pmdb_t *db, const char *dbfile)
return unlink(dbfile);
}
-alpm_list_t *_alpm_db_test(pmdb_t *db)
-{
- struct dirent *ent;
- char path[PATH_MAX];
- char text[PATH_MAX+1];
- struct stat buf;
- alpm_list_t *ret = NULL;
-
- while ((ent = readdir(db->handle)) != NULL) {
- if(!strcmp(ent->d_name, ".") || !strcmp(ent->d_name, "..")) {
- continue;
- }
- /* check for desc, depends, and files */
- snprintf(path, PATH_MAX, "%s/%s/desc", db->path, ent->d_name);
- if(stat(path, &buf)) {
- snprintf(text, PATH_MAX, _("%s: description file is missing"), ent->d_name);
- ret = alpm_list_add(ret, strdup(text));
- }
- snprintf(path, PATH_MAX, "%s/%s/depends", db->path, ent->d_name);
- if(stat(path, &buf)) {
- snprintf(text, PATH_MAX, _("%s: dependency file is missing"), ent->d_name);
- ret = alpm_list_add(ret, strdup(text));
- }
- snprintf(path, PATH_MAX, "%s/%s/files", db->path, ent->d_name);
- if(stat(path, &buf)) {
- snprintf(text, PATH_MAX, _("%s: file list is missing"), ent->d_name);
- ret = alpm_list_add(ret, strdup(text));
- }
- }
- return(ret);
-}
-
int _alpm_db_open(pmdb_t *db)
{
ALPM_LOG_FUNC;