Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/lib/libalpm/db.c
diff options
context:
space:
mode:
authorAurelien Foret <aurelien@archlinux.org>2005-10-08 20:43:25 +0000
committerAurelien Foret <aurelien@archlinux.org>2005-10-08 20:43:25 +0000
commit0d6a2edaa8e39f9d7b77f0a023e8a2bfdab7a16d (patch)
treecc22b868e74e5e716cbaa8ed0b6f2629b978ade4 /lib/libalpm/db.c
parent5ef51b3e266cf43411947248886372001fdb207a (diff)
Moved the REPLACES and FORCE package fields from DESC to DEPENDS db entry
Diffstat (limited to 'lib/libalpm/db.c')
-rw-r--r--lib/libalpm/db.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/lib/libalpm/db.c b/lib/libalpm/db.c
index cee36454..7052d132 100644
--- a/lib/libalpm/db.c
+++ b/lib/libalpm/db.c
@@ -346,22 +346,12 @@ int db_read(pmdb_t *db, char *name, unsigned int inforeq, pmpkg_t *info)
}
_alpm_strtrim(tmp);
info->size = atol(tmp);
- } else if(!strcmp(line, "%REPLACES%")) {
- /* the REPLACES tag is special -- it only appears in sync repositories,
- * not the local one. */
- while(fgets(line, 512, fp) && strlen(_alpm_strtrim(line))) {
- info->replaces = pm_list_add(info->replaces, strdup(line));
- }
} else if(!strcmp(line, "%MD5SUM%")) {
/* MD5SUM tag only appears in sync repositories,
* not the local one. */
if(fgets(info->md5sum, sizeof(info->md5sum), fp) == NULL) {
return(-1);
}
- } else if(!strcmp(line, "%FORCE%")) {
- /* FORCE tag only appears in sync repositories,
- * not the local one. */
- info->force = 1;
}
}
fclose(fp);
@@ -417,6 +407,16 @@ int db_read(pmdb_t *db, char *name, unsigned int inforeq, pmpkg_t *info)
while(fgets(line, 512, fp) && strlen(_alpm_strtrim(line))) {
info->provides = pm_list_add(info->provides, strdup(line));
}
+ } else if(!strcmp(line, "%REPLACES%")) {
+ /* the REPLACES tag is special -- it only appears in sync repositories,
+ * not the local one. */
+ while(fgets(line, 512, fp) && strlen(_alpm_strtrim(line))) {
+ info->replaces = pm_list_add(info->replaces, strdup(line));
+ }
+ } else if(!strcmp(line, "%FORCE%")) {
+ /* FORCE tag only appears in sync repositories,
+ * not the local one. */
+ info->force = 1;
}
}
fclose(fp);