[Reproducible-commits] [dpkg] 06/32: dpkg-divert: fix return value of rename_mv
Holger Levsen
holger at layer-acht.org
Tue May 3 08:43:12 UTC 2016
This is an automated email from the git hooks/post-receive script.
holger pushed a commit to annotated tag 1.15.10
in repository dpkg.
commit 9387f083bec3d94312e1f80162a29d73809feded
Author: Raphaël Hertzog <hertzog at debian.org>
Date: Thu Mar 17 14:35:53 2011 +0100
dpkg-divert: fix return value of rename_mv
This is a regression introduced by the C rewrite of dpkg-divert
(commit 02b12d75f1eff7c184fafb5a663a0421e9a645ea) that made it unable to
rename files when that rename implies a copy on another file system.
The code has provision to do a copy when a simple rename is not enough
but the associated function erroneously returned a failure value when
that operation was performed.
Reported-by: Durk Strooisma
---
debian/changelog | 5 +++++
src/divertcmd.c | 2 +-
2 files changed, 6 insertions(+), 1 deletion(-)
diff --git a/debian/changelog b/debian/changelog
index 61f863b..8ea05ab 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -6,6 +6,11 @@ dpkg (1.15.8.11) UNRELEASED; urgency=low
* Add missing semicolon to the vsnprintf() compat declaration.
Thanks to Robert Millan. Closes: #612203
+ [ Raphaël Hertzog ]
+ * Fix a regression in dpkg-divert where using --rename led to a failure when
+ the rename implies crossing file systems. Thanks to Durk Strooisma for
+ spotting it.
+
[ Updated man page translations ]
* German (Helge Kreutzmann). Minor fixe(s).
diff --git a/src/divertcmd.c b/src/divertcmd.c
index 1e7614f..3b176af 100644
--- a/src/divertcmd.c
+++ b/src/divertcmd.c
@@ -256,7 +256,7 @@ rename_mv(const char *src, const char *dst)
varbuf_destroy(&tmpdst);
- return -1;
+ return 0;
}
static void
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/reproducible/dpkg.git
More information about the Reproducible-commits
mailing list