summaryrefslogtreecommitdiff
path: root/ftparchive/writer.cc
diff options
context:
space:
mode:
authorMichael Vogt <mvo@debian.org>2013-08-08 15:40:15 +0200
committerMichael Vogt <mvo@debian.org>2013-08-08 15:40:15 +0200
commitf52037d629aea696f938015e7f1ec037eb079af8 (patch)
tree925b27ed34466ec12778ba90728b0d1b358fc7f8 /ftparchive/writer.cc
parente9737c7f6a3e03b2975927ef9b04c1194026ed9c (diff)
fix -Wall errors
Diffstat (limited to 'ftparchive/writer.cc')
-rw-r--r--ftparchive/writer.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/ftparchive/writer.cc b/ftparchive/writer.cc
index 3283128d8..7ecfe78ed 100644
--- a/ftparchive/writer.cc
+++ b/ftparchive/writer.cc
@@ -284,7 +284,8 @@ bool FTWScanner::Delink(string &FileName,const char *OriginalPath,
if (link(FileName.c_str(),OriginalPath) != 0)
{
// Panic! Restore the symlink
- symlink(OldLink,OriginalPath);
+ if (symlink(OldLink,OriginalPath) != 0)
+ _error->Errno("symlink", "failed to restore symlink");
return _error->Errno("link",_("*** Failed to link %s to %s"),
FileName.c_str(),
OriginalPath);