ref: refs/heads/master
commit 12cd269fcea1ebcdccc4b5fd87d9279f616baef7
Author: Michael Schroeder
Date: Mon Jun 22 14:13:51 2009 +0200
- fix internalize logic
---
ext/repo_products.c | 4 ++++
ext/repo_releasefile_products.c | 10 ++--------
2 files changed, 6 insertions(+), 8 deletions(-)
diff --git a/ext/repo_products.c b/ext/repo_products.c
index 5cdcc19..7325cd7 100644
--- a/ext/repo_products.c
+++ b/ext/repo_products.c
@@ -551,6 +551,10 @@ repo_add_products(Repo *repo, const char *proddir, const char *root, int flags)
/* no luck. print an error message in case the root argument is wrong */
perror(fullpath);
join_freemem();
+
+ /* the least we can do... */
+ if (!(flags & REPO_NO_INTERNALIZE) && (flags & REPO_REUSE_REPODATA) != 0)
+ repodata_internalize(repo_last_repodata(repo));
}
/* EOF */
diff --git a/ext/repo_releasefile_products.c b/ext/repo_releasefile_products.c
index 2413d20..9277395 100644
--- a/ext/repo_releasefile_products.c
+++ b/ext/repo_releasefile_products.c
@@ -144,13 +144,7 @@ repo_add_releasefile_products(Repo *repo, const char *dirpath, int flags)
closedir(dir);
join_freemem();
- if (!(flags & REPO_NO_INTERNALIZE))
- {
- if (!(flags & REPO_REUSE_REPODATA))
- {
- Repodata *data = repo_add_repodata(repo, 0);
- repodata_internalize(data);
- }
- }
+ if (!(flags & REPO_NO_INTERNALIZE) && (flags & REPO_REUSE_REPODATA) != 0)
+ repodata_internalize(repo_last_repodata(repo));
}
--
To unsubscribe, e-mail: zypp-commit+unsubscribe@opensuse.org
For additional commands, e-mail: zypp-commit+help@opensuse.org