The following commit has been merged in the master branch:
commit e2dd70725de2d227267b138688eea21bdb5d2004
Author: Guillem Jover <[email protected]>
Date: Sun Oct 7 02:59:28 2012 +0200
dpkg: Do not consider obsolete conffiles as actively owned by the package
This ensures conffile entries are not misshandled nor mixed up when
configuring packages owning the non-obsolete conffiles. Otherwise we
end up with bogus entries in the database, which could cause unpack
failures, leftover directories on removal or wrong processing of
conffiles.
Closes: #689836
Based-on-patch-by: Andreas Beckmann <[email protected]>
Signed-off-by: Guillem Jover <[email protected]>
diff --git a/debian/changelog b/debian/changelog
index 848c44e..f59d385 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -31,6 +31,10 @@ dpkg (1.16.9) UNRELEASED; urgency=low
This makes sure to reinclude directories previously excluded so that
contained files marked for inclusion do not fail to unpack due to a
missing directory. Closes: #688416
+ * Do not consider obsolete conffiles as actively owned by the package.
+ This ensures conffile entries are not misshandled nor mixed up when
+ configuring packages owning the non-obsolete conffiles. Closes: #689836
+ Based on a patch by Andreas Beckmann <[email protected]>.
[ Updated programs translations ]
* Czech (Miroslav Kure).
diff --git a/src/archives.c b/src/archives.c
index 5c3e4d1..35f1bb1 100644
--- a/src/archives.c
+++ b/src/archives.c
@@ -197,6 +197,8 @@ md5hash_prev_conffile(struct pkginfo *pkg, char *oldhash,
const char *oldname,
if (otherpkg->status <= stat_unpacked)
continue;
for (conff = otherpkg->installed.conffiles; conff; conff = conff->next) {
+ if (conff->obsolete)
+ continue;
if (strcmp(conff->name, namenode->name) == 0)
break;
}
diff --git a/src/configure.c b/src/configure.c
index 79740d8..a826f0e 100644
--- a/src/configure.c
+++ b/src/configure.c
@@ -391,8 +391,11 @@ deferred_configure(struct pkginfo *pkg)
* version is in the conffiles data for the package. If
* ‘*.dpkg-new’ no longer exists we assume that we've
* already processed this one. */
- for (conff = pkg->installed.conffiles; conff; conff =
conff->next)
+ for (conff = pkg->installed.conffiles; conff; conff =
conff->next) {
+ if (conff->obsolete)
+ continue;
deferred_configure_conffile(pkg, conff);
+ }
pkg_set_status(pkg, stat_halfconfigured);
}
diff --git a/src/help.c b/src/help.c
index c64a243..06e09a4 100644
--- a/src/help.c
+++ b/src/help.c
@@ -218,6 +218,8 @@ dir_has_conffiles(struct filenamenode *file, struct pkginfo
*pkg)
pkg_name(pkg, pnaw_always));
namelen = strlen(file->name);
for (conff= pkg->installed.conffiles; conff; conff= conff->next) {
+ if (conff->obsolete)
+ continue;
if (strncmp(file->name, conff->name, namelen) == 0 &&
conff->name[namelen] == '/') {
debug(dbg_veryverbose, "directory %s has conffile %s from %s",
--
dpkg's main repository
--
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]